We want to run e2e testing within GitHub action for ou React Native iOS application.
We use macos-12
GitHub runner for running test, and building the iOS simulator build.
Build steps succeed locally and in the runner.
The build from the runner does not work both in the runner and locally, while my local build work fine in the runner and locally.
This is the debug log I get from the runner when trying to launch the builded app within the simulator in the CI : https://gist.github.com/kopax-polyconseil/cd31322d8d71b664a0c965be7a1607e0#file-ios-log-L28
The relevant part is:
Library not loaded: @rpath/hermes.framework/hermes
Referenced from: /Users/USER/Library/Developer/CoreSimulator/Devices/7C23C39D-FA27-425C-9B5C-FB06AC4A982C/data/Containers/Bundle/Application/61E9F720-7C7A-4822-9B34-F52954645757/PassCulture.app/PassCulture
Reason: tried: '/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 15.2.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift/hermes.framework/hermes' (no such file), '/usr/lib/swift/hermes.framework/hermes' (no such file), '/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 15.2.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift/hermes.framework/hermes' (no such file), '/usr/lib/swift/hermes.framework/hermes' (no such file), '/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 15.2.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift/hermes.framework/hermes' (no such file), '/usr/lib/swift/hermes.framework/hermes' (no such file), '/Users/dka/Library/Developer/CoreSimulator/Devices/7C23C39D-FA27-425C-9B5C-FB06AC4A982C/data/Container
(terminated at launch; ignore backtrace)
These are related issue I have found:
- Library not loaded: @rpath/hermes.framework/hermes
- https://github.com/facebook/react-native/issues/34601
It seems hermes is not found when starting the app within the simulator.
We use react-native 0.68.5, the GitHub action CI takes 2hours to perform this build and it is painful.
All proposed workaround I found tells how to configure xcode with a GUI, which is not possible in the GitHub action environment.
How can I fix this hermes problem in a CI environment ?