Skip to content

Commit 98d02c3

Browse files
chore: fix tests
1 parent 0920dfc commit 98d02c3

2 files changed

Lines changed: 16 additions & 8 deletions

File tree

maestro/helpers/helpers.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -141,17 +141,17 @@ verify_runtime_ready() {
141141
if [ "$PLATFORM" != "android" ]; then
142142
return 0 # iOS doesn't need this check - runtime is on localhost
143143
fi
144-
local max_attempts=10
144+
local max_attempts=5 # Reduced from 10 since we're checking from host side
145145
local attempt=1
146146
echo "Verifying Mendix runtime connectivity..."
147147
while [ "$attempt" -le "$max_attempts" ]; do
148-
# Use adb to check if localhost:8080 is reachable from the emulator's perspective
149-
if adb shell "curl -s -o /dev/null -w '%{http_code}' http://localhost:8080/" 2>/dev/null | grep -q "200\|302"; then
150-
echo "✅ Runtime is reachable from emulator (attempt $attempt)"
148+
# Check from host side (runner) - if host can reach it, the adb reverse tunnel will work
149+
if curl -fsS -o /dev/null --max-time 2 "http://localhost:8080/" 2>/dev/null; then
150+
echo "✅ Runtime is reachable (attempt $attempt)"
151151
return 0
152152
fi
153153
echo "Runtime not ready yet (attempt $attempt/$max_attempts), waiting..."
154-
sleep 3
154+
sleep 2
155155
attempt=$((attempt + 1))
156156
done
157157
echo "⚠️ Runtime verification timed out - proceeding anyway (app will handle connection errors)"

packages/pluggableWidgets/intro-screen-native/e2e/specs/maestro/IntroScreen.yaml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,21 +39,29 @@ appId: "${APP_ID}"
3939
timeout: 5000
4040
- tapOn:
4141
text: "OK"
42+
# Wait for dialog to dismiss before navigating back
43+
- extendedWaitUntil:
44+
visible: "Go back"
45+
timeout: 3000
4246
- tapOn: "Go back"
47+
# Wait for widgets menu to appear before tapping intro screen again
48+
- extendedWaitUntil:
49+
visible: "Widgets menu"
50+
timeout: 5000
4351
- tapOn:
4452
text: "Intro screen"
4553
- extendedWaitUntil:
4654
visible: "Active slide: 2"
4755
timeout: 5000
4856
- tapOn:
4957
text: "NEXT"
50-
# Wait for slide transition to complete and FINISH button to appear
58+
# Wait for slide transition to complete - longer timeout for Android emulator
5159
- extendedWaitUntil:
5260
visible: "Active slide: 3"
53-
timeout: 5000
61+
timeout: 10000
5462
- extendedWaitUntil:
5563
visible: "FINISH"
56-
timeout: 5000
64+
timeout: 10000
5765
- tapOn:
5866
text: "FINISH"
5967
- extendedWaitUntil:

0 commit comments

Comments
 (0)