Hey All, I'm working on a contribution to WireMock...
# wiremock-java
p
Hey All, I'm working on a contribution to WireMock and I'm having a few issues. The first is that I'm getting two unit test failures just running
./gradlew build
on `master`:
Copy code
ContentPatternsJsonValidityTest > matchesJsonSchemaValidates() FAILED
    java.lang.AssertionError: 
    Expected: an empty collection
         but: <[: must be valid to one and only one schema, but 0 are valid, : required property 'equalTo' not found, : required property 'binaryEqualTo' not found, : required property 'contains' not found, : required property 'doesNotContain' not found, : required property 'matches' not found, : required property 'doesNotMatch' not found, : required property 'not' not found, : required property 'before' not found, : required property 'after' not found, : required property 'equalToDateTime' not found, : required property 'equalToJson' not found, : required property 'matchesJsonPath' not found, : required property 'equalToXml' not found, : required property 'matchesXPath' not found, /matchesJsonSchema: string found, object expected, : required property 'absent' not found, : required property 'and' not found, : required property 'or' not found, : required property 'hasExactly' not found, : required property 'includes' not found]>
        at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
        at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:6)
        at com.github.tomakehurst.wiremock.ContentPatternsJsonValidityTest.matchesJsonSchemaValidates(ContentPatternsJsonValidityTest.java:158)
I actually get two failures as the body of
matchesJsonSchemaValidates
is duplicated a few lines down in
matchesJsonSchemaWithVersionValidates
which obviously isn't intentional but I can remove the second test if required.
Seems we're getting those in the public repo builds, so I guess it's a known issue? https://github.com/wiremock/wiremock/actions/runs/14192131850/job/39758990465
(Note I deleted another question regarding an issue with Spotless which was caused by our admins not allowing a
master
branch originally so we had to rename it
main
. We've resolved that now but spotless was pointing at the old
main
branch 🤦‍♂️ )
t
Hey Paul, apologies for the delayed reply to this. We’re a bit behind due to easter holidays but will be reviewing open PRs including this one tomorrow.
p
No worries, thanks @Tom, appreciate it 🙂