rebreak-monorepo/apps/rebreak-native/.maestro/stress/dm-scroll-performance.yaml
chahinebrini 63fae25531 fix(android-protection): explicit specialUse FGS type — Samsung/Android 16 crash loop
RebreakVpnService.onStartCommand crashed with SecurityException because Android 16's validateForegroundServiceType rejects the implicit 2-arg startForeground(). Now passes FOREGROUND_SERVICE_TYPE_SPECIAL_USE explicitly (Google's documented best practice) and guards the call so a failed foreground promotion stops the service cleanly instead of crashing the app. Verified vs reported Galaxy A54 / Android 16 signature (97% of crash events, 1-user crash loop).

Bundles pending working-tree work across native/marketing/locales/mac + graphify-out rebuild. gitignore: google-services.json + /screenshots/.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-10 22:33:28 +02:00

161 lines
3.9 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# stress/dm-scroll-performance.yaml
#
# Stress scenario: Open a DM conversation with many messages and scroll
# the entire history. Designed to catch FlatList perf issues on slow devices
# (Samsung A50 — primary Android test target, known slow).
#
# What this tests:
# - DM FlatList renders without ANR (App Not Responding) on large history
# - Scroll from bottom to top of message list completes
# - Scroll back to bottom (chat.scrollToBottom behavior)
# - App does not crash or freeze during scroll
# - "Scroll to bottom" action returns to latest message correctly
#
# Samsung A50 characteristics:
# - Exynos 9610 — single-core perf ~35% slower than Pixel 5
# - 4GB RAM — RN FlatList with 100+ messages + image attachments can OOM
# - Expected: 510s for initial load on large history (100 messages)
#
# Pre-requisite:
# - Test user has a DM conversation with 50+ messages (seed if not present).
# - If conversation is short: the stress value is reduced but the flow still
# validates basic scroll behavior.
# Env-Vars: E2E_TEST_USER, E2E_TEST_PASSWORD, E2E_TEST_PEER_NICKNAME
appId: org.rebreak.app
---
- launchApp:
clearState: true
# Extended wait — A50 cold boot is slow
- waitForAnimationToEnd:
timeout: 8000
# --- Auth ---
- assertVisible:
text: "E-Mail"
- tapOn:
text: "E-Mail"
- inputText: ${E2E_TEST_USER}@rebreak.internal
- tapOn:
text: "Passwort"
- inputText: ${E2E_TEST_PASSWORD}
- tapOn:
text: "Anmelden"
# Extended timeout for A50 + Staging network round-trip
- waitForAnimationToEnd:
timeout: 15000
- assertVisible:
text: "ReBreak"
# --- Navigate to Chat tab ---
- tapOn:
text: "Chat"
- waitForAnimationToEnd:
timeout: 5000
- assertVisible:
text: "Direktnachrichten"
# --- Open target DM ---
- tapOn:
text: ${E2E_TEST_PEER_NICKNAME}
# Extended load time for large message history on A50
- waitForAnimationToEnd:
timeout: 10000
# DM screen input is the load-complete signal
- assertVisible:
text: "Nachricht schreiben…"
# --- Scroll UP through history ---
# Repeat swipe-up 8 times to simulate user browsing through history.
# Each swipe = ~3 visible messages scrolled on an A50 screen.
# 8 swipes = ~24 messages reviewed without crash.
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 2000
- swipe:
direction: UP
duration: 600
- waitForAnimationToEnd:
timeout: 3000
# If the app hasn't crashed by here: FlatList is stable under upward scroll.
# --- Scroll BACK DOWN to latest message ---
# Simulate user tapping "scroll to bottom" or dragging down rapidly.
- swipe:
direction: DOWN
duration: 300
- swipe:
direction: DOWN
duration: 300
- swipe:
direction: DOWN
duration: 300
- swipe:
direction: DOWN
duration: 300
- waitForAnimationToEnd:
timeout: 3000
# --- Assert the input is still accessible after scroll ---
# If the app ANR'd or crashed, this will fail.
# If the FlatList lost keyboard/input state, this will fail.
- assertVisible:
text: "Nachricht schreiben…"
# --- Send a message after scroll to verify input still works ---
- tapOn:
text: "Nachricht schreiben…"
- inputText: "[E2E-STRESS] Scroll-Test abgeschlossen"
- pressKey: Return
- waitForAnimationToEnd:
timeout: 8000
# Message bubble appeared = send path survived after heavy scroll
- assertVisible:
text: "[E2E-STRESS] Scroll-Test abgeschlossen"