@@ -21,54 +21,63 @@ const E2eCommand = Command.extend({
2121 aliases : [ 'e' ] ,
2222 description : 'Run e2e tests in existing project.' ,
2323 works : 'insideProject' ,
24- availableOptions : overrideOptions (
25- baseServeCommandOptions . concat ( [
26- {
27- name : 'config' ,
28- type : String ,
29- aliases : [ 'c' ] ,
30- description : oneLine `Use a specific config file.
31- Defaults to the protractor config file in angular-cli.json.`
32- } ,
33- {
34- name : 'specs' ,
35- type : Array ,
36- default : [ ] ,
37- aliases : [ 'sp' ] ,
38- description : oneLine `Override specs in the protractor config.
39- Can send in multiple specs by repeating flag (ng e2e --specs=spec1.ts --specs=spec2.ts).`
40- } ,
41- {
42- name : 'element-explorer' ,
43- type : Boolean ,
44- default : false ,
45- aliases : [ 'ee' ] ,
46- description : 'Start Protractor\'s Element Explorer for debugging.'
47- } ,
48- {
49- name : 'webdriver-update' ,
50- type : Boolean ,
51- default : true ,
52- aliases : [ 'wu' ] ,
53- description : 'Try to update webdriver.'
54- } ,
55- {
56- name : 'serve' ,
57- type : Boolean ,
58- default : true ,
59- aliases : [ 's' ] ,
60- description : oneLine `Compile and Serve the app.
61- All non-reload related serve options are also available (e.g. --port=4400).`
62- }
63- ] ) , [
64- { name : 'port' , default : 0 } ,
65- {
66- name : 'watch' ,
67- default : false ,
68- description : 'Run build when files change.'
69- } ,
70- ]
71- ) ,
24+ availableOptions : overrideOptions ( [
25+ ...baseServeCommandOptions ,
26+ {
27+ name : 'config' ,
28+ type : String ,
29+ aliases : [ 'c' ] ,
30+ description : oneLine `
31+ Use a specific config file.
32+ Defaults to the protractor config file in angular-cli.json.
33+ `
34+ } ,
35+ {
36+ name : 'specs' ,
37+ type : Array ,
38+ default : [ ] ,
39+ aliases : [ 'sp' ] ,
40+ description : oneLine `
41+ Override specs in the protractor config.
42+ Can send in multiple specs by repeating flag (ng e2e --specs=spec1.ts --specs=spec2.ts).
43+ `
44+ } ,
45+ {
46+ name : 'element-explorer' ,
47+ type : Boolean ,
48+ default : false ,
49+ aliases : [ 'ee' ] ,
50+ description : 'Start Protractor\'s Element Explorer for debugging.'
51+ } ,
52+ {
53+ name : 'webdriver-update' ,
54+ type : Boolean ,
55+ default : true ,
56+ aliases : [ 'wu' ] ,
57+ description : 'Try to update webdriver.'
58+ } ,
59+ {
60+ name : 'serve' ,
61+ type : Boolean ,
62+ default : true ,
63+ aliases : [ 's' ] ,
64+ description : oneLine `
65+ Compile and Serve the app.
66+ All non-reload related serve options are also available (e.g. --port=4400).
67+ `
68+ }
69+ ] , [
70+ {
71+ name : 'port' ,
72+ default : 0 ,
73+ description : 'The port to use to serve the application.'
74+ } ,
75+ {
76+ name : 'watch' ,
77+ default : false ,
78+ description : 'Run build when files change.'
79+ } ,
80+ ] ) ,
7281 run : function ( commandOptions : E2eTaskOptions ) {
7382 const E2eTask = require ( '../tasks/e2e' ) . E2eTask ;
7483 this . project . ngConfig = this . project . ngConfig || CliConfig . fromProject ( ) ;
0 commit comments