JVM version of Pact. Enables consumer driven contract testing, providing a mock service and DSL for the consumer project, and interaction playback and verification for the service provider project.
Matching rules in junit5 consumer tests appear to produce an invalid contract, when manually adjusted to what I believe are correct matching rules, the provider is still matching on exact values.
When verifying on the provider, the following error is observed:
Expected either a "*" or path identifier in path expression "$.projects.project.['@due']" at index 19
Problem 2: Provider only matches exact values
I worked around this temporarily by adjusting all of the incorrect $.projects.project.['@id'] type problems to -> $.projects.project['@id']. This allowed the provider to progress further, but the matching rules aren't applied and thus exact values are required for a test to pass.
Matching rules in junit5 consumer tests appear to produce an invalid contract, when manually adjusted to what I believe are correct matching rules, the provider is still matching on exact values.
Versions
Versions
Repro
Problem 1: consumer produces invalid matching rules
Given a test that produces (expects) this XML Document:
It produces this pact file:
When verifying on the provider, the following error is observed:
Problem 2: Provider only matches exact values
I worked around this temporarily by adjusting all of the incorrect
$.projects.project.['@id']
type problems to ->$.projects.project['@id']
. This allowed the provider to progress further, but the matching rules aren't applied and thus exact values are required for a test to pass.