Nightwatch.js without Java -


is possible use nightwatch.js without installing java? there official selenium javascript bindings (webdriverjs, selenium-webdriver). there reason java required?

i catering javascript community trying run nightwatchjs locally without introducing java myself. if run remote selenium server, remote instance has have java server running pass off commands remote browser-specific driver. e.g.: chromedriver.

that said, under impression 1 connect standard client directly standard webdriver (chromedriver) locally without having stage java selenium-server-standalone-2.xx.0.jar server. nightwatchjs being 1st client have tried, hard find configuration work since documentation indicates nate stone saying above. examples have seen indicate location of selenium-server-standalone-2.xx.0.jar needs stipulated:

selenium": {   "start_process": true,   "server_path": "lib/selenium-server-standalone-2.53.0.jar",   "cli_args" : {     "webdriver.chrome.driver" : "/users/greg.kedge/bin/chromedriver"   },   "log_path": "integration/log" } 

he's can say: if want nightwatch start (and stop) server duration of tests ("start_process": true), seem necessary run java server.

however, through trial, if want start chromedriver on own on command line, thereby having time, can run chromedriver without java selenium standalone. caveat: attempted on os x far... so, assuming chromedriver in $path:

% chromedriver --url-base=/wd/hub starting chromedriver 2.21.371459 (36d3d07f660ff2bc1bf28a75d1cdabed0983e7c4) on port 9515 local connections allowed. 

now grab port (9515) , update nightwatch.json dictate want use chrome. setting default, set chrome-specific environment. remove "selenium" block nightwatch.json altogether , tell nightwatch can find running server and type of browser serving:

  "test_settings": {     "default": {       "launch_url": "http://localhost:8888/",        "selenium_host": "127.0.0.1",       "selenium_port": "9515",         "silent": true,       "firefox_profile": false,       "screenshots": {         "enabled": false,         "path": ""       },       "desiredcapabilities": {         "browsername": "chrome",         "javascriptenabled": true,         "acceptsslcerts": true,         "__commentout: chromeoptions" : {               "args" : ["start-fullscreen"]             }       },     }   } 

using way works me; can run nightwatch drive chrome without java selenium standalone server in-play. again, on os x using chromedriver always running. can't figure out how nightwatch manage starting/stopping chromedriver without adding java selenium standalone server mix.


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -