-
-
Notifications
You must be signed in to change notification settings - Fork 109
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
Ensure PACT_DESCRIPTION and PACT_PROVIDER_STATE env vars can be passed down to pact verify to allow selected interactions to be run #44
Comments
@bethesque from the provider side, how would we determine which provider description/state to tell the user? It's quite a blunt instrument at the moment as we get back only unstructured data from a single call to 'verify'. I see a few options here:
|
FWIW it's worth, it works for Pact Go:
|
For each failure in the pact, the ruby code outputs the command to run that individual interaction (you probably just gloss over that as it's not relevant for js/go).
If the calling code can also set an environment variable called |
The value of
I substitute in the relevant description, state and URL. |
Yep, but it doesn't do that anymore right?
|
I've already done it. |
I think that was a race condition - I can do that :) |
I've updated the code base to set |
Bother, I thought I had already. Will go and check my releases. |
It's working for me with 1.4.2. If I run PACT_INTERACTION_RERUN_COMMAND="foo" ./pact-provider-verifier -a "1.0.100" --provider-base-url http://localhost:4567 --pact-urls fail.json --provider_states_setup_url http://localhost:4567/provider-state -v I get: 3 interactions, 2 failures
Failed interactions:
foo # Greeting fail
foo # Provider state success |
I worked out why - we use the I'll update docs and have the code pass it through anyway for future safe-keepings. |
- Allow PACT_DISABLE_TOOL_VALIDITY_CHECK env var to disable tool check - Document re-running specific provider tests Fixes #44
This probably belongs in a child repo, I'm just not sure which one, so raising here!
I've removed the ruby specific output from the pact verify command (yay!)
What I would like to add is words to the effect of "to run just one interaction, please rerun the pact verify command with PACT_DESCRIPTION="..." and PACT_PROVIDER_STATE="..." environment variables set.
Can you please update to the ruby standalone version 1.4.0 and verify that the above environment variables are passed through? You should see the text
Filtering interactions by...
See pact-foundation/pact-js#84
The text was updated successfully, but these errors were encountered: