File tree Expand file tree Collapse file tree 4 files changed +186
-141
lines changed
Expand file tree Collapse file tree 4 files changed +186
-141
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,9 @@ executors:
2121 image : " windows-server-2019-vs2019:stable"
2222 resource_class : " windows.medium"
2323 shell : " bash.exe"
24+ browsers :
25+ docker :
26+ - image : ' cypress/browsers:node14.16.0-chrome90-ff88'
2427
2528jobs :
2629 win-test :
@@ -141,7 +144,7 @@ jobs:
141144 path : cypress\videos
142145
143146 release :
144- executor : cypress/base-10
147+ executor : cypress/base-14
145148 steps :
146149 - attach_workspace :
147150 at : ~/
@@ -233,7 +236,7 @@ workflows:
233236 requires :
234237 - Linux install
235238 # use executor with Chrome installed
236- executor : cypress/ browsers-chrome76
239+ executor : browsers
237240 # use browser "chrome" for running tests
238241 browser : chrome
239242 record : true
@@ -249,7 +252,7 @@ workflows:
249252 requires :
250253 - Linux install
251254 # use executor with Chrome installed
252- executor : cypress/ browsers-chrome73-ff68
255+ executor : browsers
253256 # use browser "chrome" for running tests
254257 browser : firefox
255258 record : true
Original file line number Diff line number Diff line change 1717 */
1818// eslint-disable-next-line no-unused-vars
1919module . exports = ( on , config ) => {
20- // `on` is used to hook into various events Cypress emits
21- // `config` is the resolved Cypress config
20+ on ( 'before:browser:launch' , ( browser , launchOptions ) => {
21+ if ( browser . name === 'chrome' && browser . isHeadless ) {
22+ launchOptions . args . push ( '--window-size=1280,720' )
23+ launchOptions . args . push ( '--force-device-scale-factor=1' )
24+ }
25+
26+ if ( browser . name === 'electron' && browser . isHeadless ) {
27+ launchOptions . preferences . width = 1280
28+ launchOptions . preferences . height = 720
29+ }
30+
31+ if ( browser . name === 'firefox' && browser . isHeadless ) {
32+ launchOptions . args . push ( '--width=1280' )
33+ launchOptions . args . push ( '--height=720' )
34+ }
35+
36+ return launchOptions
37+ } )
2238}
You can’t perform that action at this time.
0 commit comments