org.junit.ComparisonFailure

*Expected* :str ing *Actual* :string

Solutions on the web1006

  • via Google Groups by Unknown author, 6 months ago
    *Expected* :str ing *Actual* :string
  • via hateblo.jp by Unknown author, 1 year ago
    expected:<[expected]> but was:<[actual]>
  • via Stack Overflow by boop
    , 1 year ago
    substring(left, right) is not correct expected:&lt;ng str[]&gt; but was:&lt;ng str[i]&gt;
  • Stack trace

    • org.junit.ComparisonFailure: *Expected* :str ing *Actual* :string at org.junit.Assert.assertEquals(Assert.java:115) at org.junit.Assert.assertEquals(Assert.java:144) at com.AssertTest.testAsserts(AssertTest.java:12)

    Write tip

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

    Users with the same issue

    Once, 2 days ago
    3 times, 1 week ago
    Once, 3 weeks ago
    2 times, 1 month ago
    2 times, 1 month ago
    24 more bugmates