DEV: Improve labelling of Firefox Evergreen/ESR CI runs (#18313)

Both versions are used with `--headless`, so labelling one "Firefox" and the other "Firefox Headless" doesn't really make sense. Evergreen / ESR are better descriptions.
This commit is contained in:
David Taylor 2022-09-21 15:34:26 +01:00 committed by GitHub
parent 42d226f727
commit b0a9d8b761
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 8 deletions

View File

@ -184,7 +184,11 @@ jobs:
strategy:
fail-fast: false
matrix:
browser: ["Chrome", "Firefox", "Headless Firefox"]
browser: ["Chrome", "Firefox ESR", "Firefox Evergreen"]
env:
TESTEM_BROWSER: ${{ (startsWith(matrix.browser, 'Firefox') && 'Firefox') || matrix.browser }}
TESTEM_FIREFOX_PATH: ${{ (matrix.browser == 'Firefox Evergreen') && '/opt/firefox-evergreen/firefox' }}
steps:
- uses: actions/checkout@v2
@ -222,17 +226,17 @@ jobs:
- name: Core QUnit 1
if: ${{ !cancelled() }}
working-directory: ./app/assets/javascripts/discourse
run: sudo -E -u discourse -H yarn ember exam --path /tmp/emberbuild --split=3 --partition=1 --launch "${{ matrix.browser }}" --random
run: sudo -E -u discourse -H yarn ember exam --path /tmp/emberbuild --split=3 --partition=1 --launch "${{ env.TESTEM_BROWSER }}" --random
timeout-minutes: 15
- name: Core QUnit 2
if: ${{ !cancelled() }}
working-directory: ./app/assets/javascripts/discourse
run: sudo -E -u discourse -H yarn ember exam --path /tmp/emberbuild --split=3 --partition=2 --launch "${{ matrix.browser }}" --random
run: sudo -E -u discourse -H yarn ember exam --path /tmp/emberbuild --split=3 --partition=2 --launch "${{ env.TESTEM_BROWSER }}" --random
timeout-minutes: 15
- name: Core QUnit 3
if: ${{ !cancelled() }}
working-directory: ./app/assets/javascripts/discourse
run: sudo -E -u discourse -H yarn ember exam --path /tmp/emberbuild --split=3 --partition=3 --launch "${{ matrix.browser }}" --random
run: sudo -E -u discourse -H yarn ember exam --path /tmp/emberbuild --split=3 --partition=3 --launch "${{ env.TESTEM_BROWSER }}" --random
timeout-minutes: 15

View File

@ -60,14 +60,15 @@ module.exports = {
"--js-flags=--max_old_space_size=4096",
].filter(Boolean),
Firefox: ["-headless", "--width=1440", "--height=900"],
"Headless Firefox": ["--width=1440", "--height=900"],
},
browser_paths: {
"Headless Firefox": "/opt/firefox-evergreen/firefox",
},
reporter: Reporter,
};
if (process.env.TESTEM_FIREFOX_PATH) {
module.exports.browser_paths ||= {};
module.exports.browser_paths["Firefox"] = process.env.TESTEM_FIREFOX_PATH;
}
const target = `http://127.0.0.1:${process.env.UNICORN_PORT || "3000"}`;
if (process.argv.includes("-t")) {