`npm run protractor` doesn't work on win7 x64
npm-debug.log file
0 info it worked if it ends with ok
1 verbose cli [ 'D:\Program Files\nodejs\node.exe',
1 verbose cli 'D:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'protractor' ]
2 info using [email protected]
3 info using [email protected]
4 verbose node symlink D:\Program Files\nodejs\node.exe
5 verbose run-script [ 'preprotractor', 'protractor', 'postprotractor' ]
6 info preprotractor [email protected]
7 verbose unsafe-perm in lifecycle true
8 info protractor [email protected]
9 verbose unsafe-perm in lifecycle true
10 info [email protected] Failed to exec protractor script
11 verbose stack Error: [email protected] protractor: protractor test/protractor-conf.js
11 verbose stack Exit status 1
11 verbose stack at EventEmitter.protractor test/protractor-conf.js
19 error Exit status 1
20 error Failed at the [email protected] protractor script 'protractor test/protractor-conf.js'.
20 error This is most likely a problem with the angular-phonecat package,
20 error not with npm itself.
20 error Tell the author that this fails on your system:
20 error protractor test/protractor-conf.js
20 error You can get their info via:
20 error npm owner ls angular-phonecat
20 error There is likely additional logging output above.
21 verbose exit [ 1, true ]
You should set "chromeOnly" to "false" in protractor-conf.js file then try to run protractor again. Here is my config file
exports.config = {
allScriptsTimeout: 11000,
specs: [
'e2e/*.js'
],
capabilities: {
'browserName': 'chrome'
},
chromeOnly: false,
baseUrl: 'http://localhost:8000/',
framework: 'jasmine',
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 30000
}
};
Hope this helps!
the solution mentioned by dongidea doesn't work on my system (Windows 7 64bit), here are details
protractor-conf.js
exports.config = { allScriptsTimeout: 11000,
specs: [ 'e2e/*.js' ],
capabilities: { 'browserName': 'chrome' },
chromeOnly: false,
baseUrl: 'http://localhost:8000/',
framework: 'jasmine',
jasmineNodeOpts: { defaultTimeoutInterval: 30000 }
};
npm-debug.log
0 info it worked if it ends with ok
1 verbose cli [ 'c:\nodejs\node.exe',
1 verbose cli 'c:\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'protractor' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'preprotractor', 'protractor', 'postprotractor' ]
5 info preprotractor [email protected]
6 verbose unsafe-perm in lifecycle true
7 info protractor [email protected]
8 verbose unsafe-perm in lifecycle true
9 info [email protected] Failed to exec protractor script
10 verbose stack Error: [email protected] protractor: protractor test/protractor-conf.js
10 verbose stack Exit status 1
10 verbose stack at EventEmitter.protractor test/protractor-conf.js
18 error Exit status 1
19 error Failed at the [email protected] protractor script 'protractor test/protractor-conf.js'.
19 error This is most likely a problem with the angular-phonecat package,
19 error not with npm itself.
19 error Tell the author that this fails on your system:
19 error protractor test/protractor-conf.js
19 error You can get their info via:
19 error npm owner ls angular-phonecat
19 error There is likely additional logging output above.
20 verbose exit [ 1, true ]
Did you have the error message RangeError: port should be >= 0 and < 65536: 104125
I encountered a similar problem, please refer the following post
http://stackoverflow.com/questions/30134415/protractor-on-64-bit-node-have-rangeerror-the-port-excced-the-range-0-65536
I'm getting exactly the same output as the same as imsma above. I tried changing 'chomeOnly' to 'false', with no change. Also Win7 64bit.
I came here because I had the same error description as above. With further investigation, I discovered that I had an outdated chromedriver. An issue has already been opened up for this, with a solution: https://github.com/angular/angular-phonecat/issues/252
If you downloaded the phonecat tutorial between 2014-10-07 and now, you will need to complete this step before being able to run Protractor.