File tree Expand file tree Collapse file tree 4 files changed +19
-0
lines changed Expand file tree Collapse file tree 4 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ module.exports={
26
26
"specs" :"./*.spec.js" ,
27
27
"ignore_files" :"" ,
28
28
"feature_file_suppport" : false ,
29
+ "network" : false ,
29
30
} ,
30
31
"tunnel_settings" : {
31
32
"tunnel" : false ,
Original file line number Diff line number Diff line change @@ -227,6 +227,14 @@ function sync_args_from_cmd(args) {
227
227
} else {
228
228
lt_config [ "tunnel_settings" ] [ "autostart" ] = true ;
229
229
}
230
+
231
+ if ( "network" in args ) {
232
+ lt_config [ "run_settings" ] [ "network" ] = true
233
+ ? args [ "network" ] == "true"
234
+ : false ;
235
+ } else if ( ! lt_config [ "run_settings" ] [ "network" ] ) {
236
+ lt_config [ "run_settings" ] [ "network" ] = false ;
237
+ }
230
238
//get specs from current directory if specs are not passed in config or cli
231
239
if (
232
240
( lt_config [ "run_settings" ] [ "specs" ] == undefined ||
Original file line number Diff line number Diff line change @@ -120,6 +120,12 @@ module.exports = validate_config = function (lt_config) {
120
120
}
121
121
}
122
122
}
123
+ //validate if network field contains expected value
124
+ if ( "network" in lt_config [ "run_settings" ] ) {
125
+ if ( ! ( [ true , false ] . includes ( lt_config [ "run_settings" ] [ "network" ] ) ) ) {
126
+ reject ( "Error!! boolean value is expected in network key" ) ;
127
+ }
128
+ }
123
129
resolve ( "Validated the Config" ) ;
124
130
} ) ;
125
131
} ;
Original file line number Diff line number Diff line change @@ -69,6 +69,10 @@ const argv = require('yargs')
69
69
alias : 'tat' ,
70
70
describe : 'Tunnel Auto Start' ,
71
71
type : 'string'
72
+ } ) . option ( 'net' , {
73
+ alias : 'network' ,
74
+ describe : 'Capture Network logs' ,
75
+ type : 'string'
72
76
} )
73
77
} ,
74
78
function ( argv ) {
You can’t perform that action at this time.
0 commit comments