pact-provider-verifier
pact-provider-verifier copied to clipboard
feat(generators): Pass back result from provider state setup URL
Addressing issue I've previously mentioned here https://github.com/pact-foundation/pact-provider-verifier/issues/49
Best is to see what's inside a new test contract - we provide a generators object which can override the tested request. I've implemented generator ProviderState, which although is not part of the spec, is implemented in pact-jvm described here
I just want to raise a conversation early, if the approach is approvable in a future or I should change the implementation.
....
"request": {
"method": "GET",
"path": "/book/1",
"generators": {
"path": {
"type": "ProviderState",
"expression": "/book/${id}"
}
}
},
....
TODO:
- [ ] add generators to all request objects based on specification
- [ ] generators support in https://github.com/pact-foundation/pact-support/pull/79
- [ ] generators support in https://github.com/pact-foundation/pact-ruby/pull/209
@uglyog what's with the generator not being part of the spec?
Because you never wrote the spec for it ;-)
I was busy :P
Looks good though @hhhonzik, keep going!
Where is this at @hhhonzik?
Hey @hhhonzik thanks for your efforts on this pull request and others,
Are you still looking to work on them, or would you require feedback or anything to help. If not thank you and we will look to see how we can incorporate these ideas in the future
https://github.com/pact-foundation/pact-provider-verifier/issues/49 https://github.com/pact-foundation/pact-ruby/pull/209 https://github.com/pact-foundation/pact-support/pull/79
closed in favour of #85 and https://github.com/pact-foundation/pact-ruby/pull/273