Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(CI): Migrate e2e iOS to Namespace #5992

Closed
wants to merge 24 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/yarn-install/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ runs:
path: |
node_modules
*/*/node_modules
key: ${{ runner.os }}-${{ runner.arch }}-node-${{ steps.setup-node.outputs.node-version }}-${{ hashFiles('**/yarn.lock', 'patches/*.patch') }}
key: ${{ runner.os }}-${{ runner.name }}-${{ runner.arch }}-node-${{ steps.setup-node.outputs.node-version }}-${{ hashFiles('**/yarn.lock', 'patches/*.patch') }}
- name: Install Yarn dependencies
run: |
# Deals with yarn (v1) install flakiness
Expand Down
44 changes: 40 additions & 4 deletions .github/workflows/e2e-ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ jobs:
# `if` conditions can't directly access secrets, so we use a workaround
# See https://docs.github.com/en/actions/security-guides/encrypted-secrets#using-encrypted-secrets-in-a-workflow
SECRETS_AVAILABLE: ${{ secrets.SECRETS_AVAILABLE }}
BASH_ENV: ~/.profile
# BASH_ENV: ~/.profile
name: iOS (${{ inputs.ios-version }})
runs-on: ios-e2e-group
runs-on: namespace-profile-default-mac
steps:
- uses: google-github-actions/auth@v2
if: ${{ env.SECRETS_AVAILABLE }}
Expand All @@ -29,7 +29,42 @@ jobs:
secrets: |-
EMERGE_API_TOKEN:projects/1027349420744/secrets/EMERGE_API_TOKEN
- uses: actions/checkout@v4
- name: Install missing utils from namespace machine
run: |
brew tap wix/brew
brew install applesimutils
env:
HOMEBREW_NO_AUTO_UPDATE: 1
HOMEBREW_NO_INSTALL_CLEANUP: 1
- name: Cache Pods
uses: actions/cache@v4
with:
path: ./ios/Pods
key: ${{ runner.os }}-pods-${{ hashFiles('ios/Podfile', 'ios/Podfile.lock') }}

- uses: ./.github/actions/yarn-install
# - uses: actions/setup-node@v4
# id: setup-node
# with:
# node-version: 22.x
# - uses: actions/cache@v4
# with:
# path: |
# node_modules
# */*/node_modules
# key: ${{ runner.os }}-${{ runner.name }}-${{ runner.arch }}-node-${{ steps.setup-node.outputs.node-version }}-${{ hashFiles('**/yarn.lock', 'patches/*.patch') }}
# - name: Install Yarn dependencies
# run: |
# # Deals with yarn (v1) install flakiness
# yarn || yarn --network-concurrency 1
# # Another install flakiness fix (at least in yarn v1 with node 20)
# # yarn postinstall isn't always run (?!) so we run it manually
# yarn postinstall
# shell: bash
# - name: Fail if someone forgot to commit "yarn.lock"
# run: git diff --exit-code
# shell: bash

# Since the e2e runners have access to the Valora branding,
# This check ensures there are no type errors there.
# The `yarn build` step done in the test workflow also includes it but does it with the default celo branding.
Expand Down Expand Up @@ -73,9 +108,10 @@ jobs:
--record-logs=failing
--loglevel info
--debug-synchronization 10000
--maxWorkers 6
--maxWorkers 8
--retries 3
timeout-minutes: 45
--headless
timeout-minutes: 60
- name: Publish iOS JUnit Report
if: always()
uses: mikepenz/action-junit-report@v4
Expand Down
16 changes: 9 additions & 7 deletions .github/workflows/e2e-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,24 @@ on:
- main
merge_group:

workflow_dispatch:

# Cancel any in progress run of the workflow for a given PR
# This avoids building outdated code
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }}
cancel-in-progress: true

jobs:
android:
name: Android
uses: ./.github/workflows/e2e-android.yml
with:
android-api-level: 30
secrets: inherit
# android:
# name: Android
# uses: ./.github/workflows/e2e-android.yml
# with:
# android-api-level: 30
# secrets: inherit
ios:
name: iOS
uses: ./.github/workflows/e2e-ios.yml
with:
ios-version: '15.0'
ios-version: '16.2'
secrets: inherit
19 changes: 15 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -333,11 +333,18 @@
"type": "iPhone SE (2nd generation)"
}
},
"simulator.15.0": {
"simulator.15.5": {
"type": "ios.simulator",
"device": {
"type": "iPhone SE (2nd generation)",
"os": "iOS 15.0"
"os": "iOS 15.5"
}
},
"simulator.16.2": {
"type": "ios.simulator",
"device": {
"type": "iPhone SE (3rd generation)",
"os": "iOS 16.2"
}
},
"simulator.17.2": {
Expand Down Expand Up @@ -366,8 +373,12 @@
"device": "simulator",
"app": "ios.release"
},
"ios.release.15.0": {
"device": "simulator.15.0",
"ios.release.15.5": {
"device": "simulator.15.5",
"app": "ios.release"
},
"ios.release.16.2": {
"device": "simulator.16.2",
"app": "ios.release"
},
"ios.release.17.2": {
Expand Down
Loading