Skip to content
This repository has been archived by the owner on Nov 12, 2021. It is now read-only.

E2E test workflow #166

Closed
wants to merge 2 commits into from
Closed

E2E test workflow #166

wants to merge 2 commits into from

Conversation

brainrepo
Copy link

@brainrepo brainrepo commented Mar 12, 2021

Done:

This is one attempt to bring the e2e tests for the native part (ios) to the CI related to #3 .

The tests are made using appium.

The e2eios workflow builds the application using the expo server and exports it as an ipa ready for ios simulator.

We download the ipa from the expo's server and we unzip it. The ipa is unzipped (appium fails loading it triggering an error during the verification of the package, if you run appium in macOS locally you don't need to unzip it because the system does it magically for you 🤬).

We install appium and we run yarn e2e:ios:run:ci
this command start appium and run the tests concurrently

the test script runs
In this repository https://github.com/brainrepo/expo-ci-proto, you can find my first attempt.
Here the CI workflow https://github.com/brainrepo/expo-ci-proto/runs/2095445200?check_suite_focus=true
if you check line 1467 and 1468 in run appium tests step you can see that the test runs

[e2e-t] 2021-03-12T13:58:59.279Z INFO webdriver: RESULT Open up App.js to start working on your app!
[e2e-t] Message: <Open up App.js to start working on your app!>

To improve:

  • The download ipa name is hardcoded in the test file
  • The tests should be done using a test framework and the test response have to be more readable.
  • Actually, the test doesn't end because we need to switch off appium graceful.

To evaluate

This workflow relies strongly on expo server, the builds steps are doing using expo servers which are so slow. Can be interesting to become completely autonomous using turtle-cli.

Please note: to be completely independent we need to have a web server with https, to allow turtle-cli to retrieve the js payloads and the assets. Turtle-cli is a copy of expo build system, you can use it by giving the expo credentials (in this case you have to upload the payloads and assets in their servers) or you can publish in your webserver passing to turtle-cli the url. In this last case I think that we will be completely autonomous.

https://docs.expo.io/distribution/hosting-your-app/#hosting-your-static-files

@simoneb
Copy link
Member

simoneb commented Apr 23, 2021

Superseded by new work

@simoneb simoneb closed this Apr 23, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants