angular-cli
angular-cli copied to clipboard
ng e2e
Hi all! Thanks for your hard work on angular-cli. It seems that ng e2e returns a status code of 0 even when it fails. This makes continuous integration painful. I have purposefully demonstrated a scenario below where my tests fail, and I expected angular-cli to be returning 1.
$ ng e2e
> [email protected] pree2e /code/myproject/web
> webdriver-manager update
selenium standalone is up to date.
chromedriver is up to date.
> [email protected] e2e /code/myproject/web
> protractor "config/protractor.conf.js"
[18:30:07] I/direct - Using ChromeDriver directly...
[18:30:07] I/launcher - Running 1 instances of WebDriver
Spec started
myproject-web App
✗ should display message saying app works
- Failed: Angular could not be found on the page http://localhost:4200/ : retries looking for angular exceeded
**************************************************
* Failures *
**************************************************
1) myproject-web App should display message saying app works
- Failed: Angular could not be found on the page http://localhost:4200/ : retries looking for angular exceeded
Executed 1 of 1 spec (1 FAILED) in 10 secs.
[18:30:19] I/launcher - 0 instance(s) of WebDriver still running
[18:30:19] I/launcher - chrome #01 failed 1 test(s)
[18:30:19] I/launcher - overall: 1 failed spec(s)
[18:30:19] E/launcher - Process exited with error code 1
Some end-to-end tests failed, see above.
$ echo $?
0
If I run the underlying protractor configuration, I get the result I expected:
$ protractor config/protractor.conf.js
Using ChromeDriver directly...
[launcher] Running 1 instances of WebDriver
Spec started
myproject-web App
✗ should display message saying app works
- Failed: Angular could not be found on the page http://localhost:4200/ : retries looking for angular exceeded
**************************************************
* Failures *
**************************************************
1) robotic-audit-web App should display message saying app works
- Failed: Angular could not be found on the page http://localhost:4200/ : retries looking for angular exceeded
Executed 1 of 1 spec (1 FAILED) in 10 secs.
[launcher] 0 instance(s) of WebDriver still running
[launcher] chrome #1 failed 1 test(s)
[launcher] overall: 1 failed spec(s)
[launcher] Process exited with error code 1
$ echo $?
1
Issue checklist:
- OS? Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?) OS X Yosemite (10.10.5)
- Versions. Please run
ng --version
$ ng --version
angular-cli: 1.0.0-beta.5
node: 5.4.1
os: darwin x64
- Repro steps. Was this an app that wasn't created using the CLI? What change did you do on your code? etc. No changes. Generated using CLI.
- The log given by the failure. Normally this include a stack trace and some more information. See above.
+1 to this
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.