Skip to content

Commit 718befd

Browse files
Merge branch 'main' into @kacperzolkiewski/add-e2e-tests-to-ci
2 parents 6dccf89 + 3603eac commit 718befd

17 files changed

Lines changed: 206 additions & 32 deletions
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
appId: swmansion.enriched.example
2+
tags:
3+
- android-only
4+
---
5+
- launchApp
6+
- tapOn:
7+
id: "toggle-screen-button"
8+
9+
- tapOn:
10+
id: "focus-button"
11+
12+
- inputText: "EADING"
13+
- doubleTapOn:
14+
id: "editor-input"
15+
point: "10%, 50%"
16+
17+
- tapOn:
18+
id: "android:id/floating_toolbar_menu_item_text"
19+
text: "Copy"
20+
21+
# Dismiss toolbar with Copy/Cut etc. options
22+
- tapOn:
23+
id: "editor-input"
24+
- tapOn:
25+
id: "clear-button"
26+
- tapOn:
27+
id: "focus-button"
28+
29+
- tapOn:
30+
id: "toolbar-heading-1"
31+
32+
- inputText: "H"
33+
34+
- longPressOn:
35+
id: "editor-input"
36+
point: "50%, 50%"
37+
38+
- tapOn:
39+
id: "android:id/floating_toolbar_menu_item_text"
40+
text: "Paste"
41+
42+
- runFlow:
43+
file: "../subflows/capture_or_assert_screenshot.yaml"
44+
env:
45+
SCREENSHOT_NAME: "extending_paragraph_style_on_paste_after_copy"
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
appId: swmansion.enriched.example
2+
tags:
3+
- android-only
4+
---
5+
- launchApp
6+
- tapOn:
7+
id: "toggle-screen-button"
8+
9+
- tapOn:
10+
id: "focus-button"
11+
12+
- inputText: "EADING"
13+
- doubleTapOn:
14+
id: "editor-input"
15+
point: "10%, 50%"
16+
17+
- tapOn:
18+
id: "android:id/floating_toolbar_menu_item_text"
19+
text: "Cut"
20+
21+
- tapOn:
22+
id: "toolbar-heading-1"
23+
24+
- inputText: "H"
25+
26+
- longPressOn:
27+
id: "editor-input"
28+
point: "50%, 50%"
29+
30+
- tapOn:
31+
id: "android:id/floating_toolbar_menu_item_text"
32+
text: "Paste"
33+
34+
- runFlow:
35+
file: "../subflows/capture_or_assert_screenshot.yaml"
36+
env:
37+
SCREENSHOT_NAME: "extending_paragraph_style_on_paste_after_cut"
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
appId: swmansion.enriched.example
2+
---
3+
# Regression test: a link loaded from HTML must not be destroyed when the user types immediately after it.
4+
- launchApp
5+
6+
- tapOn:
7+
id: "toggle-screen-button"
8+
9+
- runFlow:
10+
file: "../subflows/set_editor_value.yaml"
11+
env:
12+
VALUE: "<a href=\"https://swmansion.com\">link</a>"
13+
14+
- tapOn:
15+
id: "editor-input"
16+
point: "5%, 50%"
17+
- tapOn:
18+
id: "editor-input"
19+
point: "95%, 50%"
20+
21+
- inputText: " extra"
22+
23+
- runFlow:
24+
file: "../subflows/capture_or_assert_screenshot.yaml"
25+
env:
26+
SCREENSHOT_NAME: "html_link_not_extended"

.maestro/flows/link_not_extended.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
appId: swmansion.enriched.example
2-
tags:
3-
- ios-only
42
---
53
# PR #421 - fix(iOS): prevent extending link styles
4+
# PR #502 - fix(android): link turns into plain text
65
- launchApp
76

87
- tapOn:
18.4 KB
Loading
18.4 KB
Loading
4.37 KB
Loading
5.5 KB
Loading
5.08 KB
Loading

.maestro/scripts/run-tests.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ if [ "$(printf '%s\n' "$MIN_MAESTRO_VERSION" "$MAESTRO_VERSION" | sort -V | head
3434
fi
3535

3636
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
37+
REPO_ROOT="$(cd "$SCRIPT_DIR/../.." && pwd)"
38+
SCREENSHOT_ROOT="$REPO_ROOT/.maestro/screenshots"
3739
BUNDLE_ID="swmansion.enriched.example"
3840

3941
PLATFORM=""
@@ -80,8 +82,8 @@ else
8082
echo "=== App ($BUNDLE_ID) already installed, skipping build ==="
8183
fi
8284

83-
EXTRA=""
84-
[ -n "$UPDATE_SCREENSHOTS" ] && EXTRA="--env UPDATE_SCREENSHOTS=true"
85+
EXTRA="--env SCREENSHOT_ROOT=$SCREENSHOT_ROOT"
86+
[ -n "$UPDATE_SCREENSHOTS" ] && EXTRA="$EXTRA --env UPDATE_SCREENSHOTS=true"
8587

8688
# Exclude tests tagged for the other platform.
8789
case "$PLATFORM" in

0 commit comments

Comments
 (0)