Does matchPath(regexPath, examplePath) makes the mock server expect request with examplePath (exact match)? #1767
Labels
bug
Indicates an unexpected problem or unintended behavior
smartbear-supported
SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear
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?
The text was updated successfully, but these errors were encountered: