我在Amazon Linux上运行以下版本的node和npm ...
[myuser@mymachine ~]$ node --version
v8.8.1
[myuser@mymachine ~]$ npm -v
5.4.2
通过
安装我的seleniuv-webdriver模块后npm install selenium-webdriver
我正在运行nodeJS测试,但收到以下错误
/home/jboss/node_modules/selenium-webdriver/index.js:25
const chrome = require('./chrome');
^^^^^
SyntaxError: Use of const in strict mode.
at Module._compile (module.js:439:25)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous> (/home/jboss/.jenkins/workspace/myco/automated-tests/nodejs/js/js-FF/Optimus-FF.js:2:15)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
我还需要做些什么来让seleniuv-webdriver运行我的命令?