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

node processes are not ended correctly for nightmare #6

Open
scharf opened this issue Apr 22, 2017 · 1 comment
Open

node processes are not ended correctly for nightmare #6

scharf opened this issue Apr 22, 2017 · 1 comment
Labels

Comments

@scharf
Copy link

scharf commented Apr 22, 2017

When I use nightmare (with dispatch:mocha) on my system (MacOS 10.12.4) in watch mode, there are lots of processes created.

This is how I start my tests:

TEST_BROWSER_DRIVER=nightmare meteor test --driver-package dispatch:mocha --port 3100

The first run starts an electron process
first-run
The second run starts a new one, but the forked node does not die:

second_run

With phantom, the forked node process dies when phantom dies.

Each time, electron is started a new node subprocess is forked which runs electron. When electron terminates, the node subprocess does not die. Over time, this adds a lot of pressure to the system.

This does not happen with phantomjs, therefore I assume that it may be a problem with this package.

@aldeed
Copy link
Contributor

aldeed commented May 9, 2017

@scharf The nightmare file is here: https://github.com/aldeed/meteor-browser-tests/blob/master/browser/nightmare.js

If you clone this repo into a folder in /packages folder in your app, then you can add logging to see if nightmare.end() is called. Notice also on line 18 where it should be calling it on exit.

So the questions are: if it's not being called for your app, why not? If it is called, then why does the process not actually exit?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants