@@ -64,28 +64,33 @@ module.exports = {
64
64
let chromeCapabilities = Capabilities . chrome ( ) ;
65
65
const options = new chrome . Options ( )
66
66
chromeCapabilities . setAcceptInsecureCerts ( true ) ;
67
+ let seleniumArgs = [
68
+ "--window-size=1920,1080" ,
69
+ "--enable-automation" ,
70
+ "guest" ,
71
+ "disable-infobars" ,
72
+ "--disable-notifications" ,
73
+ "--lang=en" ,
74
+ "--disable-search-engine-choice-screen" ,
75
+ "disable-popup-blocking" ,
76
+ "--credentials_enable_service=false" ,
77
+ "profile.password_manager_enabled=false" ,
78
+ "profile.reduce-security-for-testing" ,
79
+ "profile.managed_default_content_settings.popups=1" ,
80
+ "profile.managed_default_content_settings.notifications.popups=1" ,
81
+ "profile.password_manager_leak_detection=false"
82
+ ]
83
+ if ( ! runLocal ) {
84
+ seleniumArgs . push ( "--headless=new" )
85
+ }
67
86
chromeCapabilities . set ( 'goog:chromeOptions' , {
68
87
excludeSwitches : [ // disable info bar
69
88
'enable-automation' ,
70
89
] ,
71
90
prefs : {
72
91
'profile.password_manager_enabled' : false
73
92
} ,
74
- args : [
75
- "--enable-automation" ,
76
- "guest" ,
77
- "disable-infobars" ,
78
- "--disable-notifications" ,
79
- "--lang=en" ,
80
- "--disable-search-engine-choice-screen" ,
81
- "disable-popup-blocking" ,
82
- "--credentials_enable_service=false" ,
83
- "profile.password_manager_enabled=false" ,
84
- "profile.reduce-security-for-testing" ,
85
- "profile.managed_default_content_settings.popups=1" ,
86
- "profile.managed_default_content_settings.notifications.popups=1" ,
87
- "profile.password_manager_leak_detection=false"
88
- ]
93
+ args : seleniumArgs
89
94
} ) ;
90
95
let driver = builder
91
96
. forBrowser ( 'chrome' )
0 commit comments