File tree Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Original file line number Diff line number Diff line change 2121 strategy :
2222 fail-fast : false
2323 matrix :
24- os : [ubuntu-latest, macos-latest]
24+ include :
25+ - os : ubuntu-latest
26+ BLOCKLY_WDIO_PAUSE_TIME_MS : donotoverride
27+ - os : macos-latest
28+ BLOCKLY_WDIO_PAUSE_TIME_MS : 100
2529
2630 steps :
2731 - name : Checkout experimentation plugin
6468 run : |
6569 cd main
6670 npm run test:ci
71+ env :
72+ BLOCKLY_WDIO_PAUSE_TIME_MS : ${{ matrix.BLOCKLY_WDIO_PAUSE_TIME_MS }}
6773
6874 webdriverio_tests :
6975 name : WebdriverIO tests (against pinned v12)
Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ let driver: webdriverio.Browser | null = null;
4242 * the browser.wait* functions if you need your test to wait for
4343 * something to happen after sending input.
4444 */
45- export const PAUSE_TIME = 0 ;
45+ export const PAUSE_TIME = fetchEnvironmentPauseTime ( ) ?? 0 ;
4646
4747/**
4848 * Start up WebdriverIO and load the test page. This should only be
@@ -93,6 +93,20 @@ export async function driverSetup(
9393 return driver ;
9494}
9595
96+ /**
97+ * Fetches the environmentally configured pause time for tests.
98+ *
99+ * @return The paues time, in milliseconds, for tests or null if one isn't
100+ * correctly configured.
101+ */
102+ function fetchEnvironmentPauseTime ( ) : number | null {
103+ const envPauseTimeMsStr = process . env . BLOCKLY_WDIO_PAUSE_TIME_MS ;
104+ if ( ! envPauseTimeMsStr ) return null ;
105+ const envPauseTimeMs = parseInt ( envPauseTimeMsStr ) ;
106+ if ( isNaN ( envPauseTimeMs ) ) return null ;
107+ return envPauseTimeMs ;
108+ }
109+
96110/**
97111 * End the WebdriverIO session.
98112 *
You can’t perform that action at this time.
0 commit comments