Closes #8.
Three tests asserted on whatever the instance happened to contain, so they broke as the project moved on. Each had a different cause:
Issue #4 got closed, so the row the editing flow looked for left the
open list. setUp now guarantees a fixture issue exists and reuses it
rather than creating one per run — issues cannot be deleted, so creating
per run would pile up closed ones forever.
A profile's header is Repositories 12, built from
Section("Repositories \(profile.repos.count)"), so an exact match on
"Repositories" could never match. Prefix match now.
The ui-smoke branch had been deleted. The MR flow opens a merge
request from it, which needs a source carrying a commit main does not
have. Nothing in the app or the API can create a branch — that is a push
— so setUp only checks, and skips with the reason. It failed before as
"created MR not in the list", which reads like an app bug. I recreated
the branch with a commit that documents why it exists
(.gitbay/ui-smoke.md).
That last test had a second, unrelated cause: the MR detail screen
opens at its header and the diff row sits below the fold, where a List
has not built it. A tree dump confirmed the screen was opening correctly
— the nav bar read !105 — so only the assertion was wrong. Same lazy
list problem as the two fixed earlier this week; scrollTo handles it.
178 tests pass, the three included.
The API helper added for the scratch repo is now a general
runCommand/readCommand pair, since setting up fixtures needs reads as
well as writes.