-
-
Notifications
You must be signed in to change notification settings - Fork 481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pact content-type override for text/plain to xml is not picked up #1812
Comments
With this change, you will need to use the full content type, i.e., |
Thx. I tried your suggestion, but it still matches as plain text: |
Did you use the latest version, or build Pact-JVM yourself? This hasn't been released yet. |
Sorry, misread your message. Will wait until released and try again. |
4.6.11 has been released |
are you able to retry @peterhagens-coder and if complete we can close this issue. thanks! |
Retried and confirmed the solution works. Thank you! |
I'm using the
pact.content_type.override
system property to override the matchers for text/plain to be xml.System.setProperty("pact.content_type.override.text/plain", "xml");
However, this is not working.I verified the system property is being picked up (e.g. by testing overriding bla/bla to json and verify this works). However, it's not possible for me to override text/plain to use xml. (The reason I need to do this is that the provider I'm testing actually expects xml content but puts a content-type of text/plain).
In the debug logs of my test, I see the PlainText matchers is still used.
DEBUG a.c.dius.pact.core.matchers.Matching.matchBody - Found a matcher for text/plain -> au.com.dius.pact.core.matchers.PlainTextContentMatcher@d6c9b3c
(Note: I will also need this later in the pact-stub-server)
Version used:
The text was updated successfully, but these errors were encountered: