fix(mobile): the folder Move UI test follows the 2.55 prompt and waits for focus - #38
Merged
Merged
Conversation
…s for focus MoveDirectoryUITests failed on every run since 1.13.0 with "the Move prompt did not open". It found the core's Move prompt by the placeholder "inbox/Work", but core 2.55.0 (ZenNotes/zennotes#844) made the prompt speak the sidebar's language: the placeholder became "<notes root> (type a folder to change)" and destinations are typed as the sidebar shows them, with no inbox/ in front. The test now matches the placeholder's fixed ending (the root's name depends on the vault) and types the destination's own path, which works on an Inbox vault and on one whose notes live at the root. With the lookup fixed, the test still failed now and then while typing ("Neither element nor any descendant has keyboard focus"). From core 2.52.0 to 2.60.0 the dialog shell focused the prompt's input on open, so the keyboard came up by itself and lifted the sheet; the test's tap, aimed at the field's frame from before the lift, blurred it again (seen frame by frame in the run's recording). The desktop fix that restores tap-first is ZenNotes/zennotes 0c3071a6. The test no longer depends on either behavior: it gives the field a moment to take focus and taps only when it did not, which also covers a hardware keyboard keeping the software one down. The New folder step uses the same helper. iPhone 17 Pro Max (iOS 27) simulator: three iterations in a row passed on a clean vault (35.3 s, 34.0 s, 37.5 s), each removing its own fixture, and the test passed again on a build with the tap-first core packed in.
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
MoveDirectoryUITestsfailed on every run since 1.13.0 ("the Move prompt did not open"): it looked for the placeholderinbox/Work, which core 2.55.0 ([Bug] Moving Notes shows wrong folders zennotes#844) replaced with<notes root> (type a folder to change). The test now matches the placeholder's fixed ending and types the destination the way the sidebar shows it (noinbox/prefix), so it works on Inbox vaults and root-notes vaults alike.focusPromptFieldhelper waits for focus and taps only if the field did not take it, so the test passes with either behavior. The New folder step uses it too.0c3071a6onv2.61.0; this shell picks it up with the nextcore:adopt.Verification
MoveDirectoryUITestspassed 3 iterations in a row on a clean vault (35.3 s, 34.0 s, 37.5 s), each removing its own fixture folders.boundaries:checkpasses).Review notes
Failed runs (before this fix) left
MoveSrc*/MoveDst*folders in the simulator's vault; those were removed. The test still leaves its fixture behind if it fails midway, as before.