Skip to content

Commit

Permalink
test(ci): use node v18, JDK17, xcode-latest, macos-12 in CI
Browse files Browse the repository at this point in the history
more modern toolchains - only avoiding macos-13+xcode-15 because
the iOS performance is so terrible there

that means we still rely on using the named iOS simulator "iPhone 14",
which does not exist by default on fresh Xcode 15 installs, but you may
create the Simulator definition easily, and it's still more modern than
previous iPhone 12
  • Loading branch information
mikehardy committed Dec 13, 2023
1 parent 95eeb05 commit d0c55db
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 31 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
submodules: recursive
- uses: actions/setup-node@v2
with:
node-version: '14'
node-version: 18
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
Expand Down Expand Up @@ -54,7 +54,7 @@ jobs:
submodules: recursive
- uses: actions/setup-node@v2
with:
node-version: '14'
node-version: 18
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
Expand Down Expand Up @@ -88,7 +88,7 @@ jobs:
submodules: recursive
- uses: actions/setup-node@v2
with:
node-version: '14'
node-version: 18
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
Expand Down
16 changes: 5 additions & 11 deletions .github/workflows/tests_e2e_android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:

- uses: actions/setup-node@v2
with:
node-version: 14
node-version: 18

# Set path variables needed for caches
- name: Set workflow variables
Expand Down Expand Up @@ -83,17 +83,11 @@ jobs:
max_attempts: 4
command: yarn --no-audit --prefer-offline && npm i -g cavy-cli

- name: Configure JDK 1.11
uses: actions/setup-java@v2
- name: Configure JDK
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: '11' # ubuntu-latest is about to default to 11, force it everywhere

- name: Verify JDK11
# Default JDK varies depending on different runner flavors, make sure we are on 11
# Run a check that exits with error unless it is 11 version to future-proof against unexpected upgrades
run: java -fullversion 2>&1 | grep '11.0'
shell: bash
distribution: 'temurin'
java-version: '17'

- name: Build Android App
uses: nick-invision/retry@v2
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/tests_e2e_ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:
jobs:
ios:
name: iOS
runs-on: macos-11
runs-on: macos-latest
# TODO matrix across APIs, at least 10 and 13 (lowest to highest)
timeout-minutes: 60
env:
Expand All @@ -30,16 +30,16 @@ jobs:

- uses: actions/setup-node@v2
with:
node-version: 14
node-version: 18

- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '13.0'
xcode-version: 'latest-stable'

- name: Start Simulator
# The first time you try to `yarn run:ios` after xcode-select, it fails, so get it out of the way...
continue-on-error: true
run: xcrun simctl boot "iPhone 12"
run: xcrun simctl boot "iPhone 14"

# Set path variables needed for caches
- name: Set workflow variables
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests_jest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
submodules: recursive
- uses: actions/setup-node@v2
with:
node-version: 14
node-version: 18
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
Expand Down
14 changes: 4 additions & 10 deletions .github/workflows/tests_junit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,11 @@ jobs:
with:
fetch-depth: 50

- name: Configure JDK 1.11
uses: actions/setup-java@v2
- name: Configure JDK
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: '11' # ubuntu-latest is about to default to 11, force it everywhere

- name: Verify JDK11
# Default JDK varies depending on different runner flavors, make sure we are on 11
# Run a check that exits with error unless it is 11 version to future-proof against unexpected upgrades
run: java -fullversion 2>&1 | grep '11.0'
shell: bash
distribution: 'temurin'
java-version: '17'

- name: Gradle Cache
uses: actions/cache@v2
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@
"tests_rn:packager": "cd tests_react_native && npx react-native start",
"tests_rn:packager:reset-cache": "cd tests_react_native && npx react-native start --reset-cache",
"run:android": "cd tests_react_native && npx react-native run-android --variant 'debug'",
"run:ios": "cd tests_react_native && npx react-native run-ios --scheme=Notifee --simulator 'iPhone 15'",
"run:ios": "cd tests_react_native && npx react-native run-ios --scheme=Notifee --simulator 'iPhone 14'",
"tests_rn:test": "cd tests_react_native && jest",
"tests_rn:test-watch": "cd tests_react_native && jest --watch",
"tests_rn:test-coverage": "cd tests_react_native && jest --coverage",
"tests_rn:android:build": "cd tests_react_native/android && ./gradlew assembleDebug -DtestBuildType=debug",
"tests_rn:android:test": "cd tests_react_native && npm_config_yes=true npx cavy-cli run-android --no-jetifier",
"tests_rn:ios:test": "cd tests_react_native && npm_config_yes=true npx cavy-cli run-ios --scheme=Notifee --simulator 'iPhone 12'",
"tests_rn:ios:test": "cd tests_react_native && npm_config_yes=true npx cavy-cli run-ios --scheme=Notifee --simulator 'iPhone 14'",
"tests_rn:ios:pod:install": "cd tests_react_native && npm_config_yes=true npx pod-install && cd .."
},
"devDependencies": {
Expand Down

0 comments on commit d0c55db

Please sign in to comment.