Skip to content
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

fix: mock server refusing connections #124

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

cakemanny
Copy link

Fixes an issue with the mock server that is use when PACT_USE_MOCKING_SERVER=yes.

Said mock server is run in a separate process, and if the process isn't bound to the port yet, connections will be refused.
This adds a notification mechanism so that the mock server is started and listening before any interactions begin.
Specifically, it hooks into the server_activate() in HTTPServer's base class

I'm aware that this pull request is unlikely to be merged as the repo has no recent activity. But perhaps this fix is useful to a potential future forker.

Fixes the mock sever that is use when `PACT_USE_MOCKING_SERVER=yes`.
Adds a notification mechanism so that the mock server is started and
listening before interactions begin.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant