title: Nightwatch - Use chromedriver
body: <p>So i saw a similar question on stack <a href="https://stackoverflow.com/questions/27601103/launch-tests-in-chrome-with-nightwatchjs-on-mac-os-connection-refused-is-sele">here</a> but it did not have an accepted answer nor did it provide me with the information i needed..</p>
  
  <p>I am trying to use 'chromedriver' because 'selenium-webdriver' requires a FF version &lt;= 28.</p>
  
  <p>What i've done so far.</p>
  
  <ul>
  <li>nightwatch.js tests running fine in FF</li>
  <li>downloaded chromedriver (<code>npm install chromedriver -g</code>) and also <code>npm install chromedriver</code> into my nightwatch project directory</li>
  <li><p>went to <code>nightwatch/bin/nightwatch.json</code> and edited the following code</p>
  
  <pre><code> "selenium" : {
  "start_process" : false,
  "server_path" : "",
  "log_path" : "",
  "host" : "127.0.0.1",
  "port" : 4444,
  "cli_args" : {
    "webdriver.chrome.driver" : "/usr/local/bin/chromedriver", &lt;= added this - is this the binary?
    "webdriver.ie.driver" : "",
    "webdriver.firefox.profile" : ""
  }},
  </code></pre></li>
  </ul>
  
  <p>also tried to update the settings for selenium to have a start_process=true and server_path</p>
  
  <pre><code> "selenium" : {
      "start_process" : true,
      "server_path" : "../selenium-server-standalone-2.39.0.jar",
      "log_path" : "",
      "host" : "127.0.0.1",
      "port" : 4444,
      "cli_args" : {
        "webdriver.chrome.driver" : "/usr/local/bin/chromedriver",
        "webdriver.ie.driver" : "",
        "webdriver.firefox.profile" : ""
      }
    },
  </code></pre>
  
  <p>Not sure if im pointing to the proper chromedriver file/folder</p>
  
  <p>also edited the test settings</p>
  
  <pre><code>  "test_settings" : {
      "default" : {
        "launch_url" : "http://localhost",
        "selenium_host" : "127.0.0.1",
        "selenium_port" : 4444,
        "silent" : true,
        "disable_colors": false,
        "screenshots" : {
          "enabled" : false,
          "path" : ""
        },
        "desiredCapabilities" : {
          "browserName" : "chrome",   &lt;= changed this from ff to chrome
          "javascriptEnabled" : true,
          "acceptSslCerts" : true
        }
      },
  </code></pre>
  
  <p>If i go to run the test (without a <code>-e &lt;browser&gt;</code>) e.g. <code>nightwatch -g &lt;group&gt;</code>, it launches fine in FF and runs..</p>
  
  <p>If i try to specify the chrome browser (<code>-e chrome</code>) <code>nightwatch -g &lt;group&gt; -e chrome</code> i get the following error</p>
  
  <pre><code>ERROR There was an error while starting the test runner:
  
  
  Error: Invalid testing environment specified: chrome
      at Object.CliRunner.parseTestSettings (/usr/local/lib/node_modules/nightwatch/lib/runner/cli/clirunner.js:354:15)
      at Object.CliRunner.init (/usr/local/lib/node_modules/nightwatch/lib/runner/cli/clirunner.js:31:8)
      at module.exports.runner.runner (/usr/local/lib/node_modules/nightwatch/lib/index.js:512:19)
      at /usr/local/lib/node_modules/nightwatch/bin/runner.js:9:16
      at module.exports.cli.cli (/usr/local/lib/node_modules/nightwatch/lib/index.js:504:7)
      at Object.&lt;anonymous&gt; (/usr/local/lib/node_modules/nightwatch/bin/runner.js:8:14)
      at Module._compile (module.js:456:26)
      at Object.Module._extensions..js (module.js:474:10)
      at Module.load (module.js:356:32)
      at Function.Module._load (module.js:312:12)
  </code></pre>
  
  <p>The questions i have are:</p>
  
  <ol>
  <li><p>How do i point to the binary file (not sure which it is)</p></li>
  <li><p>Are my settings in nightwatch.js correct? How is it running in FF if i changed the test_settings 'browserName = Chrome"?</p></li>
  <li><p>Am i missing something here?</p></li>
  </ol>
  
  <p>Thanks in advance</p>