You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 10, 2022. It is now read-only.
I'm using pact-consumer-js-dsl to generate pacts. But found interesting behaviour.
Currently I have 4 pairs of consumer-providers. I run gulp task to run the test cases with pact-dsl to generate them and they all go to the same instance of running pact_mock server. I start it before the tests run.
As a result I have 4 jsons with correct names,. The first json lists correctly the pair C1-P1 and C1P1 interactions but the second json lists C2-P2 and interaction C1P1 + C2P2. Where C = consumer, P = provider. And so on. Last json has all interactions in it but with C4P4.
How can this be overcome? I need json files with interactions specific for specific C-P pair only.
The text was updated successfully, but these errors were encountered:
Hi @ichyr, it sounds like your problem is that you are running the mock service between each C-P pair. I'm no expert on the Mock Service, however as I understand it you should start the service for each combination of C-P. Have you tried this approach?
@mefellows But this is more or less not very efficient. I'm developing Angular.js front-end application that consumed data from microservice infrastructure ( thus one consumer with multiple providers ). I have moved all my pact generation jasmine specs into seperate guild job, but they still run in one batch.
How should this be resolved?
In my opinion this is the way it is supposed to be - run all pact generation script at once.
But current implementation implies that the pact_mock-server should be fired before and shut down after each batch of test with same C-P pair. This is a mess.
We are looking at ways of fixing this, probably by creating a standard mock server for all language implementations. Unfortunately, this won't be something that can be fixed in the short term.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
@mefellows @uglyog
I'm using pact-consumer-js-dsl to generate pacts. But found interesting behaviour.
Currently I have 4 pairs of consumer-providers. I run gulp task to run the test cases with pact-dsl to generate them and they all go to the same instance of running pact_mock server. I start it before the tests run.
As a result I have 4 jsons with correct names,. The first json lists correctly the pair C1-P1 and C1P1 interactions but the second json lists C2-P2 and interaction C1P1 + C2P2. Where C = consumer, P = provider. And so on. Last json has all interactions in it but with C4P4.
How can this be overcome? I need json files with interactions specific for specific C-P pair only.
The text was updated successfully, but these errors were encountered: