Hey folks! Im trying to use some matcher for v4 s...
# pact-jvm
a
Hey folks! Im trying to use some matcher for v4 specification to check if one value is greater than other. I checked the documentation but I didn’t find references for that… Does anyone knows if is there some available matcher for this in java? Thanks guys.
b
As in ‘I’m expecting the provider to include a field ‘numberOfBananas’ in the response with a value greater than 5?’ That sounds an awful lot like something that the provider team should verify in their own tests, not something that should be part of a contract test. I’m sure a matcher like that could be added if it isn’t there already, but I’m not sure it’s a good idea..
☝️ 1
👍 1
m
It's a bit of a grey area between contract and functional testing. The question to ask here is "must this value be greater than a certain number to ensure the consumer works". If the answer is no then the check is too restrictive of the provider and belongs in a functional provide test as Bas mentions
👍 1
a
Yes, exactly… Its a grey area. Thanks for the tips, guys 🙂
👍 1