From b4cec8968b6af2de81162b4f01f211d0c41e749b Mon Sep 17 00:00:00 2001 From: julien mounier Date: Mon, 30 Oct 2023 18:22:02 +0100 Subject: [PATCH 1/2] maint(github/browserstack): reduce number of configuration tested --- .github/workflows/tests.yml | 41 ++++------ config/karma/launchers.js | 148 +++++++----------------------------- 2 files changed, 40 insertions(+), 149 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 097be35d..bcd07d19 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -8,36 +8,22 @@ jobs: fail-fast: false matrix: browser: - # - ChromeWindows11 - - ChromeWindows10 - - Chrome70Windows8 - - ChomeOSX - - Chrome70OSX - # - EdgeWindows11 - - EdgeWindows10 - - Edge88Windows8 - # - FirefoxWindows11 - - FirefoxWindows10 - - Firefox78Windows8 - - FirefoxOSX - - Firefox78OSX - - OperaOSX - - Android12Samsung - - Android12Chrome - # - Android10Chrome - # - Android8Chrome + - ChromeWindows + - Chrome80Windows + - Edge88 + - Firefox78 + - Opera70 + - Safari17 + - Safari14 + - iOS + - AndroidChrome + - Android11Samsung - Android6Chrome - - Safari15Monterey - - Safari14BigSur - - Safari13Catalina - - iOS15 - - iOS14 - - iOS13 steps: - uses: actions/checkout@v1 - uses: actions/setup-node@v2 with: - node-version: '18' + node-version: "18" - name: install packages run: yarn install - name: Tests on ${{ matrix.browser }} @@ -74,9 +60,8 @@ jobs: - macos-11 - windows-2019 node_version: - - '16' - - '18' - - '20' + - "18" + - "20" runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v1 diff --git a/config/karma/launchers.js b/config/karma/launchers.js index 2ea0ef51..5eaf73b4 100644 --- a/config/karma/launchers.js +++ b/config/karma/launchers.js @@ -8,168 +8,74 @@ const customLaunchers = { // All sorts of BrowserStack browsers, you can create your using: // https://www.browserstack.com/automate/capabilities - ChromeWindows11: { + ChromeWindows: { base: 'BrowserStack', browser: 'Chrome', os: 'Windows', os_version: '11', }, - ChromeWindows10: { + Chrome80Windows: { base: 'BrowserStack', browser: 'Chrome', os: 'Windows', - os_version: '10', - }, - Chrome70Windows8: { - base: 'BrowserStack', - browser: 'Chrome', - browser_version: '70.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) - os: 'Windows', - os_version: '8.1', // Oldest Windows version still supported - https://endoflife.date/windows - }, - ChomeOSX: { - base: 'BrowserStack', - browser: 'Chrome', - os: 'OS X', - os_version: 'Monterey', - }, - Chrome70OSX: { - base: 'BrowserStack', - browser: 'Chrome', - browser_version: '70.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) - os: 'OS X', - os_version: 'Catalina', - }, - EdgeWindows11: { - base: 'BrowserStack', - browser: 'Edge', - os: 'Windows', os_version: '11', + browser_version: '80.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/ed8c215/app/controllers/concerns/outdated_browsers.rb) }, - EdgeWindows10: { + Edge88: { base: 'BrowserStack', browser: 'Edge', os: 'Windows', - os_version: '10', - }, - Edge88Windows8: { - base: 'BrowserStack', - browser: 'Edge', - browserVersion: '88.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) - os: 'Windows', - os_version: '8.1', // Oldest Windows version still supported - https://endoflife.date/windows - }, - FirefoxWindows11: { - base: 'BrowserStack', - browser: 'Firefox', - os: 'Windows', os_version: '11', + browserVersion: '88.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/ed8c215/app/controllers/concerns/outdated_browsers.rb) }, - FirefoxWindows10: { + Firefox78: { base: 'BrowserStack', browser: 'Firefox', os: 'Windows', - os_version: '10', - }, - Firefox78Windows8: { - base: 'BrowserStack', - browser: 'Firefox', - browser_version: '78.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) - os: 'Windows', - os_version: '8.1', // Oldest Windows version still supported - https://endoflife.date/windows - }, - FirefoxOSX: { - base: 'BrowserStack', - browser: 'Firefox', - os: 'OS X', - os_version: 'Monterey', - }, - Firefox78OSX: { - base: 'BrowserStack', - browser: 'Firefox', - browser_version: '78.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) - os: 'OS X', - os_version: 'Catalina', // Oldest macOS still supported - https://endoflife.date/macos + os_version: '11', + browser_version: '78.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/ed8c215/app/controllers/concerns/outdated_browsers.rb) }, - OperaOSX: { + Opera70: { base: 'BrowserStack', browser: 'Opera', - os: 'OS X', - os_version: 'Monterey', - }, - Safari15Monterey: { - base: 'BrowserStack', - browser: 'Safari', - browser_version: '15.3', - os: 'OS X', - os_version: 'Monterey', + os: 'Windows', + os_version: '11', + browser_version: '70.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/ed8c215/app/controllers/concerns/outdated_browsers.rb) }, - Safari14BigSur: { + Safari17: { base: 'BrowserStack', browser: 'Safari', - browser_version: '14.1', os: 'OS X', - os_version: 'Big Sur', + os_version: 'Sonoma', }, - Safari13Catalina: { + Safari14: { base: 'BrowserStack', browser: 'Safari', - browser_version: '13.1', // Oldest version not blocked for Doctolib patients (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) os: 'OS X', - os_version: 'Catalina', + os_version: 'Big Sur', // == Safari '14.1' Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/ed8c215/app/controllers/concerns/outdated_browsers.rb) }, - iOS15: { + iOS: { base: 'BrowserStack', - device: 'iPhone 13', + device: 'iPhone 15', real_mobile: 'true', os: 'ios', - os_version: '15', + os_version: '17', }, - iOS14: { - base: 'BrowserStack', - device: 'iPhone 12', - real_mobile: 'true', - os: 'ios', - os_version: '14', - }, - iOS13: { - base: 'BrowserStack', - device: 'iPhone XS', - real_mobile: 'true', - os: 'ios', - os_version: '13', // Oldest version not blocked for Doctolib patients (see: https://github.com/doctolib/doctolib/blob/f381579/app/controllers/concerns/outdated_browsers.rb) - }, - Android12Samsung: { - base: 'BrowserStack', - browser: 'samsung', // version 17.0 (as of 2022-08-18) - https://en.wikipedia.org/wiki/Samsung_Internet - device: 'Samsung Galaxy S22', - real_mobile: 'true', - os: 'Android', - os_version: '12.0', - }, - Android12Chrome: { + AndroidChrome: { base: 'BrowserStack', browser: 'chrome', - device: 'Samsung Galaxy S22', + device: 'Samsung Galaxy S23', real_mobile: 'true', os: 'Android', - os_version: '12.0', + os_version: '13.0', }, - Android10Chrome: { + Android11Samsung: { base: 'BrowserStack', - browser: 'chrome', - device: 'Samsung Galaxy S20', - real_mobile: 'true', - os: 'Android', - os_version: '10.0', - }, - Android8Chrome: { - base: 'BrowserStack', - browser: 'chrome', - device: 'Samsung Galaxy S9', + browser: 'samsung', + device: 'Samsung Galaxy S21', real_mobile: 'true', os: 'Android', - os_version: '8.0', + os_version: '11.0', // Oldest version not blocked for Doctolib users (see: https://github.com/doctolib/doctolib/blob/ed8c215/app/controllers/concerns/outdated_browsers.rb) }, Android6Chrome: { base: 'BrowserStack', @@ -177,7 +83,7 @@ const customLaunchers = { device: 'Samsung Galaxy S7', real_mobile: 'true', os: 'Android', - os_version: '6.0', + os_version: '6.0', // Oldest version not blocked for Doctolib users (see. https://play.google.com/store/apps/details?id=fr.doctolib.www) }, }; From 459d3497edf7ff4fb64c3ea9aaabac8a3e5c6126 Mon Sep 17 00:00:00 2001 From: julien mounier Date: Tue, 31 Oct 2023 14:16:10 +0100 Subject: [PATCH 2/2] maint(github/actions): run checks on single node version - Other node versions are already dested in gitlab-ci --- .github/workflows/tests.yml | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index bcd07d19..f4d101dc 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -54,25 +54,17 @@ jobs: node: strategy: fail-fast: false - matrix: - os: - - ubuntu-20.04 - - macos-11 - - windows-2019 - node_version: - - "18" - - "20" - runs-on: ${{ matrix.os }} + runs-on: ubuntu-latest steps: - uses: actions/checkout@v1 - uses: actions/setup-node@v2 with: - node-version: ${{ matrix.node_version }} + node-version: "18" - name: install packages run: yarn install - name: build TypeScript run: yarn build - - name: Tests on ${{ matrix.os }} with Node ${{ matrix.node_version }} + - name: Tests on Node 18 run: yarn coverage env: BROWSER_STACK_ACCESS_KEY: ${{ secrets.BROWSER_STACK_ACCESS_KEY }}