pact-jvm
pact-jvm copied to clipboard
Does matchPath(regexPath, examplePath) makes the mock server expect request with examplePath (exact match)?
I'm asking because I observed a behavior where modifying the regex to be incompatible with the example didn't fail the test / didn't prevent the matching.
After reading the implementation of the method it seems to me MockServer uses the exact matching with the example path and the regex is just an addition into the pact and as a source of the example if not provided (using Generex).
Would it make sense to validate that the example provided explicitly matches the regex to prevent such situations?