I inherited the project in work without documentation. This is a sails.js application. There is a small set of unit tests and an end-to-end test.
When I try to run an end-to-end test using grunt. I get:
$ grunt e2e Running "nightwatch" task started - PID: 5440 >> Executing "default" tests (standalone) [Index] Test Suite ================== Running: Should clean the collection removing 0 places >> Connection refused! Is selenium server started?
I do not know what I can lose. It made me linger for a week.
The project has selenium-server-standalone-2.40.0.jar in grunt-nightwatch. Therefore, I take the PID - this is the start of the selenium server. If I first run the jar (outside the grunt), I get
$ grunt e2e org.openqa.grid.selenium.GridLauncher main INFO: Launching a standalone server 18:38:46.189 WARN - Failed to start: SocketListener0@0.0.0.0 :4444 Exception in thread "main" java.net.BindException: Selenium is already running on port 4444. Or some other service is. at org.openqa.selenium.server.SeleniumServer.start(SeleniumServer.java:491) at org.openqa.selenium.server.SeleniumServer.boot(SeleniumServer.java:300) at org.openqa.selenium.server.SeleniumServer.main(SeleniumServer.java:245) at org.openqa.grid.selenium.GridLauncher.main(GridLauncher.java:95) >> Could not start Selenium.
Here is the nightwatch.json
{ "src_folders" : ["tests/e2e"], "custom_commands_path" : "", "custom_assertions_path" : "", "globals_path" : "", "selenium" : { "start_process" : false, "server_path" : "", "log_path" : "", "host" : "127.0.0.1", "port" : 4444, "cli_args" : { "webdriver.chrome.driver" : "", "webdriver.ie.driver" : "" } }, "test_settings" : { "default" : { "launch_url" : "http://localhost", "selenium_port" : 4444, "selenium_host" : "localhost", "silent": true, "screenshots" : { "enabled" : false, "path" : "" }, "desiredCapabilities": { "browserName": "chrome", "javascriptEnabled": true, "acceptSslCerts": true } }, "chrome" : { "desiredCapabilities": { "browserName": "chrome", "javascriptEnabled": true, "acceptSslCerts": true } } } }
Thank you so much for any help!
ps In window 7 window