Repository navigation
Replace the Maestro flow with gekko UI tests for Android and iOS - #140
Open
rschattauer wants to merge 1 commit into
Open
rschattauer wants to merge 1 commit into
rschattauer wants to merge 1 commit into
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Replaces
maestro/GalwayBus.flowwith a gekko test that runsunchanged on Android and iOS, and switches the two CI jobs over. The scenario is the same as before: fresh
install -> Routes tab -> route 402 -> map with live bus positions.
Locally the UI test runs about 4-6x faster than the Maestro flow (table below).
What is gekko?
gekko runs UI tests written once in YAML on Android and iOS, just faster and with the possibility to self-heal.
actions, so steps take milliseconds and there are no screenshot heuristics. It knows when the screen has settled,
so there are no hard-coded sleeps.
gekko run). On iOS the CLI injects the agent into the simulator app at launch, so theiOS project needs no changes and no dependency.
--healmode exists but isopt-in and is not used here. This could be used locally to fix/create/edit UI tests!
Why
Merlin Park", "Route 402", "Updated.*") and needed
waitForAnimationToEndworkarounds. The gekko test selectsby ids shared by both platforms and asserts on structure, not on live content.
platform:(the Android-only "Map loaded" check).Results
Whole-command wall-clock seconds, from cleared app data. 1 untimed warm-up, then 10 timed runs per cell; all runs
passed.
Method: gekko ran against this branch's build (with the agent), Maestro against the previous upstream build with
the original flow; the app was reinstalled from the matching build before each block. Headless Google APIs
emulator (API 36) and an iPhone simulator on one Mac. The times include tool start-up, but not app build,
emulator boot or install. On GitHub-hosted runners those dominate the job, so the job-level saving will be smaller
than the test-level one.
Things to know
testTags are behaviour-neutral. TheRoute.Map.Loadedstep needs a working Maps key, which CI alreadyprovides through
GOOGLE_API_KEY; without one the map never reports "loaded".maestrois renamedui-tests. Update the required status check if branch protection uses it.Testing
gekko runpasses on Android (emulator) and iOS (simulator), 10+ runs eachactionlintRun locally:
./gradlew :androidApp:assembleDebug, thengekko run --project gekko --platform android --install(--platform iosfor the simulator build).Happy to adjust, or to keep the Maestro flow alongside for a while if you prefer.