Release 2.12.0 not compatible with AssertJ release 3.15.0
uhafner opened this issue · 3 comments
uhafner commented
After upgrading my project to assertj 3.15.0 JsonUnit fails due to a removed method:
java.lang.NoSuchMethodError: org.assertj.core.api.StringAssert.as(Ljava/lang/String;[Ljava/lang/Object;)Lorg/assertj/core/api/AbstractAssert;
at net.javacrumbs.jsonunit.assertj.JsonAssert.isString(JsonAssert.java:203)
at net.javacrumbs.jsonunit.assertj.JsonAssert.asString(JsonAssert.java:208)
at io.jenkins.plugins.analysis.warnings.recorder.RemoteApiITest.assertThatToolsContains(RemoteApiITest.java:171)
at io.jenkins.plugins.analysis.warnings.recorder.RemoteApiITest.shouldReturnAggregation(RemoteApiITest.java:160)
(See also CI build)
My test case snippet that causes the problem:
assertThatJson(tools.get(i))
.node("latestUrl")
.asString()
.matches("http://localhost:\\d+/jenkins/job/test\\d+/1/" + expectedId);
lukas-krecan commented
Hi, thanks for reporting it. It seems that AssertJ indeed moved the method from AbstractAssert class to Descriptable interface default method which is source compatible but not binary compatible change. I will rebuild the project which should fix it.
lukas-krecan commented
Released as 2.13.0
uhafner commented
Thank you very much!