Skip to content

Commit

Permalink
fix: run xCode 16 on macos 15 (#686)
Browse files Browse the repository at this point in the history
## 📜 Description

An attempt to fix iOS 18 e2e tests. 

## 💡 Motivation and Context

First of all I ahd to run e2e tests on `macos-15` runner because of a
recent changes introduced in
actions/runner-images#10703

I did it, but then turned out, that `macos-15` doesn't have iPhone 14 by
default. I re-generated assets for iPhone 16 Pro, now e2e tests can
start successfully, but for some reasons they don't want to pass - many
of tests that rely on matching screenshots detects a difference.
Unfortunately I can not detect the diff, because we exceed 90 minutes.

Taking all information above I decided, that current changes are good
enough to be merged - later on I can restore iOS 18 e2e tests in CI, but
tight now I want to unblock the process of merging other important PRs.

Also iOS 18 tests were not very stable. When I added them I used older
macos and older iOS to generate screenshots. Now I updated to necessary
XCode version, so I should be able to have 1:1 environment, let's see!

<!-- Why is this change required? What problem does it solve? -->
<!-- If it fixes an open issue, please link to the issue here. -->

## 📢 Changelog

<!-- High level overview of important changes -->
<!-- For example: fixed status bar manipulation; added new types
declarations; -->
<!-- If your changes don't affect one of platform/language below - then
remove this platform/language -->

### E2E

- changed iPhone 14 to iPhone 16 Pro (to match previous versions);
- regenerated assets;
- lock simulator18 version;

### CI

- run iOS 18 tests on macos-15;
- exclude iOS 18 testing from CI;

## 🤔 How Has This Been Tested?

Tested on CI.

## 📝 Checklist

- [x] CI successfully passed
- [x] I added new mocks and corresponding unit-tests if library API was
changed
  • Loading branch information
kirillzyusko authored Nov 14, 2024
1 parent 1e48494 commit 82628d5
Show file tree
Hide file tree
Showing 82 changed files with 8 additions and 12 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/ios-e2e-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ jobs:
path: example/ios/build/Build/Products/Release-iphonesimulator/KeyboardControllerExample.app/**
e2e-test:
name: ⚙️ Automated test cases (iOS-${{ matrix.devices.ios }})
runs-on: macos-14
runs-on: macos-${{ matrix.devices.macos }}
timeout-minutes: 90
env:
WORKING_DIRECTORY: example
Expand All @@ -103,12 +103,11 @@ jobs:
cancel-in-progress: true
strategy:
matrix:
devices:
[
{ ios: 15, xcode: "15.4", runtime: "15.5" },
{ ios: 16, xcode: "15.4", runtime: "16.4" },
{ ios: 17, xcode: "15.4" },
{ ios: 18, xcode: "16.0" },
devices: [
{ ios: 15, xcode: "15.4", macos: 14, runtime: "15.5" },
{ ios: 16, xcode: "15.4", macos: 14, runtime: "16.4" },
{ ios: 17, xcode: "15.4", macos: 14 },
# { ios: 18, xcode: "16.0", macos: 15 },
]
needs: build
steps:
Expand Down
7 changes: 2 additions & 5 deletions e2e/.detoxrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,8 @@ module.exports = {
simulator18: {
type: "ios.simulator",
device: {
// TODO: switch to iPhone 16 Pro when it'll be released
type: "iPhone 14",
// temporarily not lock OS version, because we are using beta XCode
// and depending on the runner the OS version can be 18.0 or 18.1
// os: "iOS 18.0",
type: "iPhone 16 Pro",
os: "iOS 18.0",
},
},
attached: {
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Binary file removed e2e/kit/assets/ios/iPhone 14/ModalBeforeOpening.png
Diff not rendered.
Binary file removed e2e/kit/assets/ios/iPhone 14/ModalJustOpened.png
Diff not rendered.
Binary file removed e2e/kit/assets/ios/iPhone 14/ModalKeyboardClosed.png
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.

0 comments on commit 82628d5

Please sign in to comment.