title: Chromedriver emulation with selenium and node
body: <p>Trying to setup e2e tests using emulation of mobile devices with chromedriver.  We are using chromedriver 2.3 on Mac OS and it appears that the supplied chromeOptions are not valid:</p>
  
  <pre><code>var webdriver = require('selenium-webdriver');
  var capabilities = {
      browserName: 'chrome',
      chromeOptions: {
          mobileEmulation: {
              deviceName: 'Apple iPhone 5'
          }
      }
  };
  
  var driver = new webdriver
          .Builder()
          .withCapabilities(capabilities)
          .build();
  
  driver.get('http://google.com');
  
  var bool = false;
  setTimeout(function () {
      bool = true;
  }, 9000);
  driver.wait(function() {
      return bool;
  }, 10000);
  
  driver.quit();
  </code></pre>
  
  <p>What am I doing wrong?  Here is the stack trace of the error:</p>
  
  <pre><code>UnknownError: unknown error: cannot parse capability: chromeOptions
  from unknown error: unrecognized chrome option: mobileEmulation
    (Driver info: chromedriver=2.3,platform=Mac OS X 10.10.1 x86_64)
      at new bot.Error (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/atoms/error.js:113:18)
      at Object.bot.response.checkResponse (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/atoms/response.js:106:9)
      at /Users/michael/cdTest/node_modules/selenium-webdriver/lib/webdriver/webdriver.js:152:24
      at /Users/michael/cdTest/node_modules/selenium-webdriver/lib/goog/base.js:1582:15
      at webdriver.promise.ControlFlow.runInNewFrame_ (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/webdriver/promise.js:1654:20)
      at notify (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/webdriver/promise.js:465:12)
      at notifyAll (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/webdriver/promise.js:442:7)
      at resolve (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/webdriver/promise.js:420:7)
      at fulfill (/Users/michael/cdTest/node_modules/selenium-webdriver/lib/webdriver/promise.js:535:5)
      at /Users/michael/cdTest/node_modules/selenium-webdriver/lib/goog/base.js:1582:15
  </code></pre>