File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,9 @@ const resolution = { width: 1024, height: 768 };
3
3
4
4
const currentBranch = branch . sync ( ) ;
5
5
6
+ // these variable are involved in the `CI_VRT_` workflows: `full` and `chrome`
7
+ // when this config is consumed by those workflows,
8
+ // VRT_MODE is passed as an env var with either value
6
9
const vrtMode = process . env . VRT_MODE ;
7
10
const VRT_MODE_CHROME = "chrome" ;
8
11
const VRT_MODE_FULL = "full" ;
@@ -15,7 +18,12 @@ const browsersToTest = () => {
15
18
{ width : resolution . width , height : resolution . height , name : 'edgechromium' }
16
19
]
17
20
18
- return browserTests . filter ( test => {
21
+ // if VRT_MODE is not specified
22
+ return vrtMode === undefined
23
+ // return full browser list
24
+ ? browserTests
25
+ // or return a filtered list based on the value of VRT_MODE
26
+ : browserTests . filter ( test => {
19
27
return vrtMode === VRT_MODE_FULL || ( vrtMode === VRT_MODE_CHROME && test . name === VRT_MODE_CHROME )
20
28
} )
21
29
}
You can’t perform that action at this time.
0 commit comments