teerapap / grunt-protractor-runner Goto Github PK
View Code? Open in Web Editor NEWA Grunt plugin for running protractor runner.
License: MIT License
A Grunt plugin for running protractor runner.
License: MIT License
Hi
I would like to be able to pass in chromeOptions --test-type and show-fps-counter on protractor.config.js I can do something like this:
capabilities: {
browserName: 'chrome',
chromeOptions: { args: ['--test-type', 'show-fps-counter=true'] }
},
Hi,
I am not able to run protractor tests using plugin on RHEL 6.5 box.
Other install information :
Node v0.11.12
grunt-cli v0.1.13
grunt v0.4.4
protractor 0.21.0
grunt-protractor-runner: latest
exports.config = {
seleniumAddress: 'http://localhost:4444/wd/hub',
capabilities: {
'browserName': 'firefox'
},
specs: ['/test/example-spec.js'],
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 20000
},
allScriptsTimeout: 20000
};
Running above script results in:
Running "protractor:e2e" (protractor) task
util.puts: Use console.log instead
Using the selenium server at http://localhost:4444/wd/hub
Fatal error: protractor exited with code: null
I tried to --verbose of grunt to capture more information, but no errors in grunt. I verified selenium start without any errors listening at 4444. (spawned by webdriver-manager start).
If this information is not sufficient, please let me know to enable more logging/ or any other pointers to catch the root cause.
Thanks.
As referenced here 165afbf
npm http GET https://registry.npmjs.org/grunt-protractor-runner
npm http 304 https://registry.npmjs.org/grunt-protractor-runner
[email protected] postinstall /home/autobuild/workspace/r10n-gui-PRs-continuous/node_modules/grunt-protractor-runner
./node_modules/.bin/webdriver-manager update
sh: ./node_modules/.bin/webdriver-manager: No such file or directory
npm ERR! weird error 127
npm ERR! not ok code 0
looks like npm is in a different cwd than expected root? unsure if npm has an env var set like $NPM_ROOT that can be used to reliably know where root is.
Hi
Chrome shows some security warning that normally you can removing using chromeOptions but the plugging ignores completely, can you please implement this please?
e.g.
capabilities: {
'browserName': 'chrome',
'chromeOptions': {
args: ['--test-type']
}
}
please see angular/protractor#919
Should require.resolve('protractor')
provide a reference to a _global_ install of protractor? I have protractor installed globally, not locally, but opening up a node session throws an error:
node
> require.resolve('protractor');
Error: Cannot find module 'protractor'
at Function.Module._resolveFilename (module.js:338:15)
at Function.require.resolve (module.js:384:19)
at repl:1:9
at REPLServer.self.eval (repl.js:110:21)
at repl.js:249:20
at REPLServer.self.eval (repl.js:122:7)
at Interface.<anonymous> (repl.js:239:12)
at Interface.EventEmitter.emit (events.js:95:17)
at Interface._onLine (readline.js:202:10)
at Interface._line (readline.js:531:8)
Assuming this is the same error when I run grunt protractor
:
grunt protractor:dev
Running "protractor:dev" (protractor) task
Warning: Cannot find module 'protractor' Use --force to continue.
Aborted due to warnings.
This stackoverflow post makes me wonder if require
does in fact check globally?
Hey there,
I'm having some trouble booting up selenium.
If I just issue the command:
$ protractor test/conf.js
... everything works fine.
However, with the following config:
protractor: {
options: {
configFile: "test/conf.js",
keepAlive: true,
noColor: false
},
e2e: {}
}
... issuing:
$ grunt protractor:e2e
I get:
Error: Unable to start selenium. You must specify either a seleniumAddress, seleniumServerJar, or saucelabs account, or use webdriver-manager.
at setUpSelenium (./node_modules/protractor/lib/runner.js:174:15)
at Object.runOnce ./node_modules/protractor/lib/runner.js:363:10)
at Object.<anonymous> (./node_modules/protractor/lib/cli.js:80:8)
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)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:901:3
Can you help me get past what is probably a really silly problem?
Thanks,
J
I would love to be able to specify:
options: {
configFile: "common_defaults.js", // Default config file
and then have multiple targets like:
test_env: {
options: {
configFile: "test_env.js", // Target-specific config file
where common_defaults.js
would be the big file with all protractor configs and test_env.js
would only contain the changes to the commons, like different baseUrl
and nothing else. Now in above example the test_env.js
completely replaces the common_defaults.js
.
Does the runner support Protractor sharding? I'm seeing a semi-frequent (50%+) instances where even with one "shard", the Protractor tests fail to ever exit because they're detecting a remaining webdriver instance, even after logging that it was shutting down the remaining instance
Shutting down selenium standalone server.
[launcher] 1 instance(s) of WebDriver still running
Shutting down selenium standalone server.
[launcher] 1 instance(s) of WebDriver still running
Please let me know what additional information you'd need
Running "protractor" task
Using SauceLabs selenium server at http://adamquadmon:[email protected]:80/wd/hub
/home/travis/build/xxx/node_modules/protractor/node_modules/selenium-webdriver/lib/webdriver/promise.js:1542
throw error;
^
UnknownError: Unexpected server error.
my .travis.yml:
language: node_js
node_js:
- "0.10"
before_script:
- gem install compass
- npm install -g bower
- npm install -g protractor
- npm install grunt-cli
- npm install
- bower install
script:
#- grunt test:mocha:saucelabs
- grunt test:jasmine:saucelabs # this is grunt-protractor-runner
addons:
sauce_connect:
username: "adamquadmon"
access_key: "xxx"
hosts:
- xxx.com
that's why I think the issue is related to this task.
Has anyone figured out how to efficiently run tests on multiple browsers? I have been thinking of different approaches around this idea:
capabilities
.Thoughts?
Hello,
ive installed multiple versions of firefox on the selenium-node machine. Now ill want to run frontend-tests with protractor via grunt on the different versions.
First of all, here are the important parts of my Selenium-Node configuration file:
"capabilities":
[
{
"browserName": "firefox",
"version": "25",
"firefox_binary": "C:\\Program Files (x86)\\Mozilla Firefox 25\\firefox.exe",
"firefox_profile": "Firefox_25",
"platform": "WINDOWS",
"maxInstances": 1
},
{
"browserName": "firefox",
"version": "26",
"firefox_binary": "C:\\Program Files (x86)\\Mozilla Firefox 26\\firefox.exe",
"firefox_profile": "Firefox_26",
"platform": "WINDOWS",
"maxInstances": 1
},
...
if i setup my protractor configuration file like this:
exports.config = {
baseUrl: 'http://10.1.8.157:2000',
seleniumAddress: 'http://10.1.8.157:4444/wd/hub',
specs: ['frontendtests/*.js'],
framework: 'jasmine',
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 30000
},
allScriptsTimeout: 20000,
// Default capabilities to be passed to the webdriver instance.
capabilities: {
browserName: 'firefox',
version: '26',
platform: 'WINDOWS'
}
};
the tests will be executed in the correct firefox version 26 browser on selenium-node.
If ill comment out the capabilities in my protractor configuration file and setup the Gruntfile.js like this:
protractor: {
options: {
configFile: 'protractor.conf.js',
},
run: {},
firefox25: {
options: {
args: {
capabilities: {
browserName: 'firefox',
version: '25',
platform: 'WINDOWS'
}
}
}
}
...
}
The selenium hub says:
INFO: Got a request to create a new session: Capabilities [{platform=WINDOWS, browserName=firefox, version=25}]
like if ill define the capabilities in protractor configuration file, but on the test-executing machine there is an exception:
UnknownError: Error forwarding the new session cannot find : Capabilities [{platform=WINDOWS, browserName=firefox, version=25}]
So it seems, the request to the selenium-hub does work, but whats the problem now?
According to gruntjs/grunt#1114
It is a problem in grunt-protractor-runner
I see
Running "protractor:run" (protractor) task
Using the selenium server at http://localhost:4444/wd/hub
[launcher] Running 1 instances of WebDriver[launcher] chrome passed
>>
>> Test failed but keep the grunt process alive.
Done, without errors.
Can you confirm it is a problem in this project?
Running this command:
./node_modules/grunt-protractor-runner/node_modules/.bin/webdriver-manager update --standalone --chrome
Backtrace:
Updating selenium standalone
downloading http://selenium-release.storage.googleapis.com/2.41/selenium-server-standalone-2.41.0.jar...
Updating chromedriver
downloading https://chromedriver.storage.googleapis.com/2.9/chromedriver_linux64.zip...
/workspace/client/node_modules/grunt-protractor-runner/node_modules/protractor/bin/webdriver-manager:123
throw new Error('Got code ' + res.statusCode + ' from ' + fileUrl);
^
Error: Got code 302 from http://selenium-release.storage.googleapis.com/2.41/selenium-server-standalone-2.41.0.jar
at ClientRequest. (/workspace/client/node_modules/grunt-protractor-runner/node_modules/protractor/bin/webdriver-manager:123:13)
at ClientRequest.g (events.js:175:14)
at ClientRequest.EventEmitter.emit (events.js:95:17)
at HTTPParser.parserOnIncomingClient as onIncoming
at HTTPParser.parserOnHeadersComplete as onHeadersComplete
at Socket.socketOnData as ondata
at TCP.onread (net.js:525:27)
Found a possible solution at this url:
http://stackoverflow.com/questions/7323932/how-do-you-follow-an-http-redirect-in-node-js
if i set my capabilities
capabilities: {
browserName: 'chrome',
maxInstances: 2
},
i get this error
er\promise.js:1635
throw error;
^
Error: Server has not been started.
it runs fine for maxInstance = 1
Hi,
First, thanks for this wonderful plugin!
Yesterday protractor got a huge update with a completely new syntax.
The version is 0.12.0:
https://npmjs.org/package/protractor
while grunt-protractor-runner still looks for 0.11.0.
Please upgrade the plugin. thanks!
Here is my Gruntfile.js:
module.exports = function (grunt) {
grunt.initConfig({
protractor: {
options: {
configFile: 'protractor.conf.js'
},
all: {
}
}
});
grunt.loadNpmTasks('grunt-protractor-runner');
};
When I run "grunt protractor", I get this output and nothing else:
Running "protractor:all" (protractor) task
I tried adding a console.log call inside the task definition and that is not output.
Setting keepAlive
by default to true
is counter-intuitive. In the default configuration it causes the Grunt run to not fail even if tests fail. I know no other task that does this by default, there's a reason --force
is not a default switch in Grunt.
Please, change the default to false.
I would like to have support of capabilities, so I can have different tests run the same configuration file with different selenium capabilities
Such as (Gruntfile.js):
grunt.initConfig( {
...
protractor: {
options: { // Global options
configFile: "test/protractorConf.js", // Default config file
args: {
seleniumServerJar: './test/e2e/selenium-server-standalone-2.37.0.jar',
baseUrl: 'http://localhost',
}
},
chrome: { // Chrome Specific options
args: {
capabilities: {
'browserName': 'chrome'
}
}
},
firefox: { // Firefox Specific options
args: {
capabilities: {
'browserName': 'firefox'
}
}
},
safari: { // Safari Specific options
args: {
capabilities: {
'browserName': 'safari'
}
}
},
ie: { // Internet Explorer Specific options
args: {
capabilities: {
'browserName': 'internet explorer'
}
}
}
},
...
});
Thanks!
Is it possible to use grunt-protractor-runner with latest Protractor? Currently the
package.json specifies that:
"dependencies": {
"protractor": ">=0.14.0-0 <1.0.0"
}
Would it be possible to change this to just:
"dependencies": {
"protractor": ">=0.14.0-0"
}
Hi,
I am trying to pass parameters from grunt file to jasmine test cases but unable to get the parameters in jasmine test cases or protractor config file.
i am using bellow code in grunt .
protractor: {
options: {
keepAlive: true,
configFile: "test/configfile.js",
args: {
params:{
username:'username1'
}
}
},
singlerun: {},
auto: {
keepAlive: true,
options: {
args: {
seleniumPort: 4444,
}
}
}
}
i am trying to retrieve the in test cases as browser.username
Regards
omPrakash
Protractor does not work with Firefox version >= 32. This is because Firefox 32 is broken with selenium <= 2.42.2 (http://stackoverflow.com/questions/25676328/protractor-with-firefox-32-latest-browser-not-loading)
This plugin should be updated to grab and use at least selenium 2.43 when running the webdriver-manager-update script.
Thanks!
Here is my current Grunt configuration:
protractor: { options: { configFile: 'protractor.conf.js', // Default config file keepAlive: true, // If false, the grunt process stops when the test fails. debug: false, args: { // Arguments passed to the command } }, e2e: { } }
and if I grunt using this config everything runs as expected. As soon as I change the debug to true, I get
< debugger listening on port 5858
connecting....
and it never connects, eventually timing out. Seems like the debug options does not function or I might be doing something wrong. Any help will be appreciated.
in the config file I have a suites defined
suites: {
createQuote: [
'specs/EQ/createOppertunity.spec.js',
'specs/EQ/CreateQuote.spec.js'
],
config: [
'./specs/EQ/addE72.spec.js',
'./specs/EQ/addPremesisEquipment.spec.js',
'./specs/EQ/addXCVRSEquipment.spec.js',
'./specs/EQ/addSoftwareServiceVerify.spec.js'
],
lineItemGrid: [
'./specs/line-item-grid/line-item-grid.spec.js',
'./specs/line-item-grid/changeDiscount.spec.js'
],
output: [
'./specs/output/changeNodes.spec.js',
'./specs/output/EQOutput.spec.js',
]
}
Running protractor straight from the command line gives me the correct results.
Running protractor from grunt tells me that no files match.
Lots of new commits in protractor. All the way up to version 1.3.1. Would be great to update this project to bring in all the new magic.
If you are amenable to this let me know and i will provide a PR.
Currently is seems that if I specify config like this:
protractor: {
options: {
args: {
browser: grunt.option('browser') || 'firefox'
}
}
functional: {
options: {
args: {
baseUrl: 'http://something:' + (grunt.option('port') || '9999')
}
}
}
}
Then I lose the protractor.options.args values (i.e. the browser). These only work if I remove the args from the target. The target option args should override the main options args rather than removing them completely.
Downgrading to 0.2.1 worked well for me in resolving this. I'm not sure if the use of minijasminenode is contributing to this issue, however, I was running into this while trying to run a remote test on a selenium grid.
Currently running Windows 7
Warning:
C:...\node_modules\jasmine-reporters\src\jasmine.console_reporter.js:2
if (! jasmine) {
^
ReferenceError: jasmine is not defined
at C:...\node_modules\jasmine-reporters\src\jasmine.console_reporter.js:2:11
at Object. (C:...\node_modules\jasmine-reporters\src\jasmine.console_reporter.js:1
42:3)
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)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object. (C:...\node_modules\jasmine-reporters\src\load_reporters.js:1:63)
at Module._compile (module.js:456:26) Use --force to continue.
Is there any way of modifying angular global constants from protractor runner configuration?
browser.params is always an empty object.
I want to run a specific suite that is specified in the protractor config, how can i run it.
other times i might want to run all the suites for regression, how can i do that as well.
Currently i have a task that i run, as a part of this task i want to mention a specific suite to be executed.
grunt protractor:e2eLocalSmoketest
Hello,
I would like to run multiple protractor tests via Grunt. Here is how my setup is:
I have test dir with test1Spec.js, test2Spec.js, โฆ., testnSpec.js
I have a configuration file protractorIntegrationTestsConf.js with specs listed like this:
specs: [
'../src/test/integration/test1Spec.js',
'../src/test/integration/test2Spec.js',
'../src/test/integration/test3Spec.js',
.
.
.
'../src/test/integration/testnSpec.js'
],
And, my Gruntfile.js has the following protractor task in it
protractor: {
options: {
configFile: "config/protractorIntegrationTestsConf.js",
keepAlive: false,
noColor: false,
singleRun: false,
},
run_chrome: {
options: {
args: {
browser: "chrome"
}
}
},
run_firefox: {
options: {
args: {
browser: "firefox"
}
}
},
run_phantomjs: {
options: {
args: {
browser: "phantomjs"
}
}
}
},
When I run my protractor config file with just protractor all the specs get run in sequence they are listed in config file, but when I try to run it via grunt, all the tests start running simultaneously and the grunt build fails. What is that I am doing wrong here in my setup? Can someone please help me?
Thanks,
Divya
In order to display results in gerrit, you need to export as junit xml reports. The junitreport and output flag exists within jasmineNode but it isn't in the jasmineNodeOpts. Could this be added?
grunt.initConfig({
protractor:{
options:{
args:{
baseUrl: 'http:\\www.github.com'
}
},
firefox:{
options:{
args:{
browser: 'firefox',
baseUrl: 'http:\\www.github.com' // This is needed as the value from above is ignored.
}
},
When I run protractor with
$protractor config/e2e.conf.js
It works without a problem but when I try to run it when grunt I get a chrome driver not found error
/Users/Alfred/Development/git/f1/Web/f1/test/node_modules/protractor/lib/driverProviders/local.dp.js:42
throw new Error('Could not find chromedriver at ' +
^
Error: Could not find chromedriver at /Users/Alfred/Development/git/f1/Web/f1/test/node_modules/protractor/selenium/chromedriver.exe
at LocalDriverProvider.addDefaultBinaryLocs_ (/Users/Alfred/Development/git/f1/Web/f1/test/node_modules/protractor/lib/driverProviders/local.dp.js:42:15)
at LocalDriverProvider.setupEnv (/Users/Alfred/Development/git/f1/Web/f1/test/node_modules/protractor/lib/driverProviders/local.dp.js:59:8)
at Runner.run (/Users/Alfred/Development/git/f1/Web/f1/test/node_modules/protractor/lib/runner.js:308:31)
at process. (/Users/Alfred/Development/git/f1/Web/f1/test/node_modules/protractor/lib/runFromLauncher.js:32:14)
at process.EventEmitter.emit (events.js:98:17)
at handleMessage (child_process.js:318:10)
at Pipe.channel.onread (child_process.js:345:11)
[launcher] Runner Process Exited With Error Code: 8
Fatal error: protractor exited with code: 1
Heres my config file:
protractor: {
options: {
configFile: "config/e2etest.conf.js",
keepAlive: false,
},
chrome: {
options: {
args: {
browser: "chrome"
}
}
},
firefox: {
options: {
args: {
browser: "firefox"
}
}
},
safari: {
options: {
args: {
browser: "safari"
}
}
}
}
Hi!
In the readme I can see
options.args
Type: Object Default value: {}
Arguments passed to the command. These arguments can also be supplied via command-line too.
But I can't figure out how I can pass complex params from command line, e.g. this
grunt protractor --params.someParam=someVal
doesn't work as expected.
The instructions for global protractor to work, the instructions talk about doing things with require() I did not have those problems.
I got it working with the following:
Note: webdriver-manager update is done to install down the chromedriver install.
I commented out the following in my protractor configuration for when I was using the internal protractor. They are no longer needed while using the global install.
// seleniumServerJar: PATH_TO_SERVER JAR,
// chromeDriver: DRIVER_PATH,
I did not have to delete the node_modules/protractor as the instructions show.
My solution requires 3 terminal windows though:
When my Jasmine test starts with like
it('should select a default user', function () {
I would like to see the title output in the Grunt CLI, something like
Selenium standalone server started at http://192.168.xxx.xx:35848/wd/hub
- it should select a default user
Finished in 6.001 seconds
Is that possible?
Hi! I installed grunt-protractor-runner.
Added the following to my gruntFile:
protractor: {
options: {
configFile: 'test/config/protractor.conf.js',
keepAlive: false
}
}
My protractor configuration specifies my sauce username and key and not a seleniumJar.
If I run protractor from terminal then my tests are executed fine in Sauce Labs .
When i try to run protractor using grunt my tests do not run. I just get a Done, without errors immediately.
I have protractor 0.12.1
and grunt-protractor-runner 0.1.8.
Can this be a configuration issue or is SauceLabs support not working yet?
Thank you
After up updating to 0.2.2 npm install fails:
+ npm install
npm http GET https://registry.npmjs.org/grunt-protractor-runner
npm http 304 https://registry.npmjs.org/grunt-protractor-runner
> [email protected] install /var/lib/jenkins/jobs/DEPLOY-DEV-residential-microsite/workspace/node_modules/grunt-protractor-runner
> ./node_modules/protractor/bin/webdriver-manager update
sh: ./node_modules/protractor/bin/webdriver-manager: No such file or directory
npm ERR! [email protected] install: `./node_modules/protractor/bin/webdriver-manager update`
npm ERR! Exit status 127
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the grunt-protractor-runner package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! ./node_modules/protractor/bin/webdriver-manager update
npm ERR! You can get their info via:
npm ERR! npm owner ls grunt-protractor-runner
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.4.48-45.46.amzn1.x86_64
npm ERR! command "/opt/node/bin/node" "/opt/node/bin/npm" "install"
npm ERR! cwd /var/lib/jenkins/jobs/xxx/workspace
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /var/lib/jenkins/jobs/xxx/workspace/npm-debug.log
npm ERR! not ok code 0
Build step 'Execute shell' marked build as failure
Finished: FAILURE
Hello,
I installed nodejs, grunt, bower and when I tried to run grunt e2e command, I'm getting the below error:
C:\workspace\iCORDS\iCORDS\iCORDS>grunt e2e
Running "shell:protractor" (shell) task
Warning: spawn ENOENT Use --force to continue.
Aborted due to warnings.
Can someone please help me with this issue.
Thanks in advance!
Madhu
I'm getting this error when I run the task. I have protractor installed globally and it runs correctly using command line protractor
. Not sure what the issue is...
I'm trying to make my build a bit more flexible by allowing some parameters to be set using grunt options rather than having multiple sets of config. I want to have my protractor tests run locally by default, or against a selenium grid if I use an option (using a default grid if I give no value, or the grid specified), so I tried some config like this:
protractor: {
options: {
seleniumAddress: grunt.option('grid') ? (grunt.option('grid') === true ? 'http://defaultGrid/wd/hub' : grunt.option('grid')) : null,
}
}
However protractor ends up trying to use the null value rather than start up the local selenium server. I'd like it to treat having a null (or undefined, or whatever) value for seleniumAddress as no value.
(I'm currently working around this by having the options value require'd from another file which builds the args properly, but it would be much nicer to be able to do this inline in the grunt config - much clearer to see what is going on when you look at the grunt config)
I just noticed reading the code (and saw that it was in the docs too) that I can implement my original example config as protractor-runner will allow a seleniumAddress option by default, so I updated my example to what I am actually trying to do...
We have a setup of grunt protractor runner which runs suites.
Whenever there is an error on any one of the tests, it just quits the grunt process altogether.
protractor: {
options: {
configFile: 'test/conf/protractor.conf.js',
keepAlive: true
},
'e2e': {
options: {
keepAlive: true,
noColor: false,
args: {
browser: 'chrome'
}
}
}
}
Tried the keepAlive: true & false both and no difference.
It would be better if we can have some way to handle exceptions.
"grunt-protractor-runner": "^1.0.0",
"grunt-protractor-webdriver": "^0.1.8",
This is how my config looks:
protractor: {
e2e: {
configFile: "protractor.conf.js",
keepAlive: false
}
}
But when my test fails the grunt process exits with a success.
Finished in 25.275 seconds
10 tests, 19 assertions, 8 failures
Done, without errors.
I use a pre-push hook in Git to run my tests. This hook should prevent me from pushing if the test fails. This now doesn't work because as far as git/the command knows everything is successful.
From packages.json:
...
"protractor": "~0.11.0",
"grunt-protractor-runner": "~0.1.3",
...
Error on command line after running npm install:
npm ERR! peerinvalid The package protractor does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer [email protected] wants protractor@~0.10.0
$ npm i
...
$ npm test
> [email protected] test /Users/mgol/Documents/projects/public/grunt-protractor-runner
> grunt test
Running "clean:tests" (clean) task
Running "protractor:testTargetConfigFile" (protractor) task
/Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/lib/driverProviders/local.js:42
throw new Error('Could not find chromedriver at ' +
^
Error: Could not find chromedriver at /Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/selenium/chromedriver.exe
at LocalDriverProvider.addDefaultBinaryLocs_ (/Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/lib/driverProviders/local.js:42:15)
at LocalDriverProvider.setupEnv (/Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/lib/driverProviders/local.js:59:8)
at Runner.run (/Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/lib/runner.js:206:31)
at Object.init (/Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/lib/launcher.js:135:12)
at Object.<anonymous> (/Users/mgol/Documents/projects/public/grunt-protractor-runner/node_modules/protractor/lib/cli.js:129:23)
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)
at Module.require (module.js:364:17)
>>
Fatal error: protractor exited with code: 8
npm ERR! Test failed. See above for more details.
npm ERR! not ok code 0
Address: https://travis-ci.org/kitemao/Domino
UnknownError: chrome not reachable
Hi,
Really new to frontend development and the protractor workflow. I sure would love to avoid the 10+s startup penalty of end to end tests. It seems like keepAlive is the way to go and your docs mention using watch (assuming grunt-watch?). Could you provide a doc with an example of how you'd configure this. I'd find it super helpful.
Thanks!
The following config isn't working as expected:
jasmineNodeOpts: {
// onComplete will be called just before the driver quits.
onComplete: function(runner, log) {
console.log('DONE!');
},
// If true, display spec names.
isVerbose: true,
// If true, print colors to the terminal.
showColors: true,
// If true, include stack traces in failures.
includeStackTrace: true,
// Default time to wait in ms before a test fails.
defaultTimeoutInterval: 30000
}
Seems that onComplete
is never called.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.