Aditya Parab 3bbf175bab fix(@angular/cli): do not run e2e task if build fails
when ng e2e --serve=true is run and the build is not successful e2e task
should not be run

previously the e2e task was run even if build was a failure which will
obviously result in failure of test cases
now if errors are detected in build the e2e task will not be run
update docs as well to reflect this behaviour

Closes #7567
2017-10-06 09:59:47 -07:00

1.8 KiB

ng e2e

Overview

ng e2e serves the application and runs end-to-end tests

Running end-to-end tests

ng e2e

End-to-end tests are run via [Protractor] (https://angular.github.io/protractor/).

Options

config

--config (aliases: -c)

Use a specific config file. Defaults to the protractor config file in `.angular-cli.json`.

element-explorer

--element-explorer (aliases: -ee) default value: false

Start Protractor's [Element Explorer](https://github.com/angular/protractor/blob/master/docs/debugging.md#testing-out-protractor-interactively) for debugging.

serve

--serve (aliases: -s) default value: true

Compile and Serve the app. All serve options are also available. The live-reload option defaults to false, and the default port will be random.

NOTE: Build failure will not launch the e2e task. You must first fix error(s) and run e2e again.

specs

--specs (aliases: -sp) default value: []

Override specs in the protractor config. Can send in multiple specs by repeating flag (ng e2e --specs=spec1.ts --specs=spec2.ts).

webdrive-update

--webdrive-update (aliases: -wu) default value: true

Try to update webdriver.