mattermost-mobile-upstream/detox/utils
yasser khan dfc94b3c3c
test(e2e): close manual release-test gaps (#10125)
Closes manual release-test gaps for mobile (Detox + Maestro), automating new test cases and hardening flaky/CI-only failures uncovered along the way.

### New coverage automated
- **MM-T416** offline/online post-retry (Android via airplane mode; iOS ultimately marked unsupported — see below)
- **MM-T1194 / MM-T1193** custom ToS accept/decline survives relaunch
- **MM-T3251** status change via account UI (cross-user visibility)
- **MM-T510** channel-wide/keyword mention delivery — later expanded to a full 5-channel mention matrix with exact server-side counts
- **MM-T3261 (_1/_2)** Report a Problem external hand-off (browser link mode, email mode)
- **MM-T2940** iOS managed-config (MDM) pre-fill/autoconnect
- **MM-T3271/3272** opening the app from a push notification (synthetic notification payloads, background/closed states)
- Un-skipped several tests that turned out to already pass (stale skips)

### Root-caused failing tests
- **Android SQLite corruption**: traced to native Kotlin DB connections not opening in WAL mode while JSI did (post #10109) — journal-mode mismatch corrupted the store on push-triggered writes. Fixed properly with a **WAL patch** (#10117) rather than the original destructive "wipe app database" workaround, which was reverted.
- **Fabric crash** (`addViewAt`/reparent) on `SlideUpPanelItem` taps — root-caused to view flattening racing sheet mounts; fixed with `collapsable={false}` (went through a revert/re-revert once CI reproduced the crash without it).
- **Search race**: stale in-flight search results could overwrite a cleared search box — fixed with request-id tagging.
- **iOS offline detection**: multiple iterations (AAAA sampling → Cloudflare-prefix check → final decision) landed on refusing iOS offline simulation outright, since all E2E servers are Cloudflare-fronted/anycast and the address space can't be enumerated/blocked.
- **MM-T3261 config patch** intermittently silently ignored by the server — root-caused to `ReportAProblemType` being environment-managed on PR Spinwicks (config PATCH returns 200 but is silently dropped); now detected and reported as a skip with proven cause, not a failure.
- **MM-T416 failed-post timing**: multiple rounds of tightening the wait bound to match the client's actual retry/backoff/timeout ceiling (ended at ~150s, derived from OkHttp/retry-interceptor math, not guessed).
- **MM-T5603 upload wait**: raised to match the client's real 180s upload timeout.
- **Classification banner suite**: fixed to verify config state directly instead of trusting a PATCH reply that the cloud sometimes drops.

### CI/reporting infra fixes
- Dedicated Maestro steps (MM-T3261, MM-T67856_4) weren't feeding into the merged JUnit report and couldn't gate pass/fail — fixed report merging/naming so they now count.
- Android Maestro logcat capture added (previously iOS-only diagnostics).
- Jest retry logic no longer discards passing results from a shard killed by timeout.
- Sharding raised 24→28.
- Removed dead Detox Pilot/Playbooks scaffolding (unused, uncovered by CI).

### Cleanup
- Comment/docs pass stripping narrative session-archaeology from long explanatory comments, keeping only load-bearing facts and CI references.
2026-09-11 09:48:02 +05:30
..
artifacts.js test(detox): re-submit RF→Detox migration without unintended UI changes (#9847) 2026-06-19 22:44:02 +05:30
build-tsio-job-config.js ci(e2e): make E2E/Override waive checks instead of cancelling runs (#9975) 2026-07-31 14:22:19 +02:00
build-tsio-job-config.test.js ci(e2e): make E2E/Override waive checks instead of cancelling runs (#9975) 2026-07-31 14:22:19 +02:00
cli-args.js feat(e2e): Integrate TSIO reporting (#9925) 2026-07-23 06:43:28 +00:00
cmt-channel-notify.js fix(e2e): Quarantine proven flakes and harden Detox harness (#9971) 2026-07-30 02:40:23 +05:30
cmt-channel-notify.test.js fix(e2e): Quarantine proven flakes and harden Detox harness (#9971) 2026-07-30 02:40:23 +05:30
constants.js Detox/E2E: Scripts to run tests and save report (#6560) 2022-08-13 08:37:24 -04:00
disable_ios_autofill.js test(detox): re-submit RF→Detox migration without unintended UI changes (#9847) 2026-06-19 22:44:02 +05:30
failed-jest-specs.js fix: stabilize server switch, saved posts, favorites, and related runtime races (#10122) 2026-09-09 00:35:15 +05:30
failed-jest-specs.test.js fix: stabilize server switch, saved posts, favorites, and related runtime races (#10122) 2026-09-09 00:35:15 +05:30
generate_detox_config_ci.js test(detox): re-submit RF→Detox migration without unintended UI changes (#9847) 2026-06-19 22:44:02 +05:30
jest_stare.js test(detox): re-submit RF→Detox migration without unintended UI changes (#9847) 2026-06-19 22:44:02 +05:30
maestro_report.js test(e2e): close manual release-test gaps (#10125) 2026-09-11 09:48:02 +05:30
maestro_report.test.js test(e2e): close manual release-test gaps (#10125) 2026-09-11 09:48:02 +05:30
maestro_test_cases.js feat(e2e): Integrate TSIO reporting (#9925) 2026-07-23 06:43:28 +00:00
merge-jest-results-for-tsio.js Fix/detox hittest cluster (#10023) 2026-08-27 08:58:03 +05:30
merge-jest-results-for-tsio.test.js Fix/detox hittest cluster (#10023) 2026-08-27 08:58:03 +05:30
post_message_as.js Detox/E2E: Migrate e2e javascript to typescript (#6059) 2022-03-17 17:35:26 -07:00
report.js fix: stabilize server switch, saved posts, favorites, and related runtime races (#10122) 2026-09-09 00:35:15 +05:30
report.test.js fix: stabilize server switch, saved posts, favorites, and related runtime races (#10122) 2026-09-09 00:35:15 +05:30
resolve-tsio-job-config.sh ci(e2e): per-job TSIO report groups, commit statuses, and webhook sidecar (#9969) 2026-07-29 13:45:06 +05:30
retriable_cloud_error.js test(e2e): close manual release-test gaps (#10125) 2026-09-11 09:48:02 +05:30
retriable_cloud_error.test.js test(e2e): close manual release-test gaps (#10125) 2026-09-11 09:48:02 +05:30
spec-durations.js chore(e2e): Cache app builds. Skip E2E on docs only PR. (#9930) 2026-08-04 19:13:39 +05:30
test_cases.js chore(e2e): Fix e2e artifact upload path for CMT workflow (#9955) 2026-07-21 11:44:34 +03:00
tsio-channel-notify-rollup.js fix(e2e): Quarantine proven flakes and harden Detox harness (#9971) 2026-07-30 02:40:23 +05:30
tsio-channel-notify-rollup.test.js fix(e2e): Quarantine proven flakes and harden Detox harness (#9971) 2026-07-30 02:40:23 +05:30
tsio-report-status.js ci(e2e): make E2E/Override waive checks instead of cancelling runs (#9975) 2026-07-31 14:22:19 +02:00
tsio-report-status.test.js ci(e2e): make E2E/Override waive checks instead of cancelling runs (#9975) 2026-07-31 14:22:19 +02:00
webhook_utils.js Add Multiselect, Dynamic Select, Multiform, and Field Refresh Support for Interactive Dialogs (#9484) 2026-03-18 15:15:08 -06:00
write-tsio-failure-stub.mjs feat(e2e): Integrate TSIO reporting (#9925) 2026-07-23 06:43:28 +00:00
xml_escape.test.js Fix/detox hittest cluster (#10023) 2026-08-27 08:58:03 +05:30