Skip to content

Commit

Permalink
Added tests for jsonpath compatibility with matchers; fixes gh-57
Browse files Browse the repository at this point in the history
  • Loading branch information
marcingrzejszczak committed Jun 7, 2021
1 parent e42e790 commit 358bb5b
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -849,4 +849,14 @@ class JsonAssertionSpec extends Specification {
noExceptionThrown()
}

@Issue('#57')
def 'should work with matchers'() {
given:
String json = '''{ "value": -1}'''
when:
assertThatJson(json).field("['value']").matches("-?(\\d+)")
then:
noExceptionThrown()
}

}

0 comments on commit 358bb5b

Please sign in to comment.