java.lang.AssertionError

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

Check your pattern declaration or check your assert declaration.


rafaelrafael

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • When run "mvn clean package", the test show two errors. The detail as follow: setPinTest(tachyon.shell.command.PinCommandTest) Time elapsed: 0.374 sec <<< FAILURE! java.lang.AssertionError: expected:<0> but was:<20> at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.failNotEquals(Assert.java:834) at org.junit.Assert.assertEquals(Assert.java:645) at org.junit.Assert.assertEquals(Assert.java:631) at tachyon.shell.command.PinCommandTest.setPinTest(PinCommandTest.java:84) Tests run: 4, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 63.249 sec <<< FAILURE! listenWildcardTest(tachyon.master.ServiceSocketBindIntegrationTest) Time elapsed: 62.067 sec <<< ERROR! java.lang.NullPointerException: null at tachyon.master.LocalTachyonCluster.stopTFS(LocalTachyonCluster.java:130) at tachyon.master.AbstractLocalTachyonCluster.stop(AbstractLocalTachyonCluster.java:283) at tachyon.master.LocalTachyonCluster.stop(LocalTachyonCluster.java:146) at tachyon.LocalTachyonClusterResource$1.evaluate(LocalTachyonClusterResource.java:193) at org.junit.rules.RunRules.evaluate(RunRules.java:20) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray2(ReflectionUtils.java:208) at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:158) at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:86) at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153) at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:95)
    via by coneyliu,
  • When run "mvn clean package", the test show two errors. The detail as follow: setPinTest(tachyon.shell.command.PinCommandTest) Time elapsed: 0.374 sec <<< FAILURE! java.lang.AssertionError: expected:<0> but was:<20> at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.failNotEquals(Assert.java:834) at org.junit.Assert.assertEquals(Assert.java:645) at org.junit.Assert.assertEquals(Assert.java:631) at tachyon.shell.command.PinCommandTest.setPinTest(PinCommandTest.java:84) Tests run: 4, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 63.249 sec <<< FAILURE! listenWildcardTest(tachyon.master.ServiceSocketBindIntegrationTest) Time elapsed: 62.067 sec <<< ERROR! java.lang.NullPointerException: null at tachyon.master.LocalTachyonCluster.stopTFS(LocalTachyonCluster.java:130) at tachyon.master.AbstractLocalTachyonCluster.stop(AbstractLocalTachyonCluster.java:283) at tachyon.master.LocalTachyonCluster.stop(LocalTachyonCluster.java:146) at tachyon.LocalTachyonClusterResource$1.evaluate(LocalTachyonClusterResource.java:193) at org.junit.rules.RunRules.evaluate(RunRules.java:20) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray2(ReflectionUtils.java:208) at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:158) at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:86) at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153) at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:95)
    via by coneyliu,
  • Assertion failure for calculating hour difference
    via by Unknown author,
    • java.lang.AssertionError: expected:<0> but was:<20> at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.failNotEquals(Assert.java:834) at org.junit.Assert.assertEquals(Assert.java:645) at org.junit.Assert.assertEquals(Assert.java:631) at alluxio.shell.command.PinCommandTest.setPinTest(PinCommandTest.java:79)

    Users with the same issue

    rocdayrocday
    1 times, last one,
    musketyrmusketyr
    10 times, last one,
    jokesterjokester
    3 times, last one,
    AxeloAxelo
    1 times, last one,
    pulse00pulse00
    3 times, last one,
    95 more bugmates