Mock Server not Starting
See original GitHub issueI’m currently trying to set up pact with an Angular application and Karma. When running the karma test in which the pact is generated, I always get the error “process not found”:
Error: Command failed: taskkill /f /t /pid 13344
FEHLER: Der Prozess "13344" wurde nicht gefunden.
at checkExecSyncError (child_process.js:472:13)
at Object.execSync (child_process.js:512:13)
at Server.stop (C:\daten\workspaces\pact-node-test\node_modules\@pact-foundation\pact-node\src\server.js:138:7)
at Server.<anonymous> (C:\daten\workspaces\pact-node-test\node_modules\@pact-foundation\pact-node\src\server.js:117:8)
at ChildProcess.g (events.js:292:16)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:920:16)
at Socket.<anonymous> (internal/child_process.js:351:11)
at emitOne (events.js:96:13)
After some digging, I realized this is just a subsequent error to the mock server not starting. With LOGLEVEL set to DEBUG, I get the following log output before the above:
[2017-10-07T14:40:44.300Z] DEBUG: pact-node@4.12.0/14532 on THEMACHINE:
: cannot load such file -- bundler/vendor/molinillo/lib/molinillo/modules/specification_provider (LoadError)
So, there are two issues here:
- When the mock server isn’t starting, an error should be raised so that it’s clear what went wrong. That would have saved me some trouble finding the real cause, because I was first looking into the “process not found” error 😃.
- Why do I get the LoadError? Obviously is has something to do with Ruby dependencies not being satisfied, but I’m not (yet) into Ruby enough to find out what’s wrong here.
I have prepared a minimal example at https://github.com/thombergs/pact-node-test. Running npm run start
I get the above error.
I would appreciate any hints on this issue 😉
Issue Analytics
- State:
- Created 6 years ago
- Comments:23 (19 by maintainers)
Top Results From Across the Web
Running MockServer
The Maven plugin has the following goals: start - start MockServer, do not block, but stop when build ends; stop - stop a...
Read more >Docker container not starting · Issue #1177 - GitHub
Describe the issue After recent changes the docker container is not starting using the following command: docker run --rm -it -p 1080:1080 ...
Read more >spring boot - Mockserver expectation not active - Stack Overflow
First prevent the Camel route to start (for example with the Route.configure() method),; Initialize the mocks and their expectations ...
Read more >Requests to my mock servers aren't returning the expected ...
This error means that your mock is private and requires a Postman API key to be passed in the request header named x-api-key....
Read more >How To Persist Expectations On Mock Server Restart - YouTube
Vlog channel Oyekool: https://www.youtube.com/c/Oyekool----------------------------------------⚙️Gears used⚙️Gimbal ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I got it to work with the new version, and even through karma-pact now. Thanks a lot for your efforts.
@mefellows I’ve found several things wrong with pact-standalone. I think a lot of these bugs seems to have been when I updated pact-node to 5.1.0. I’m fixing them right now, should be out shortly.