You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 0b2876c
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: docs/react-router/README.md
+18Lines changed: 18 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,3 +9,21 @@ See our [Contributing Guide](/docs/CONTRIBUTING.md).
9
9
## Testing
10
10
11
11
Refer to the [React Router Testing documentation](./testing.md) for testing the React Router package.
12
+
13
+
## Debug Logging
14
+
15
+
The `StackManager` logs the decisions behind the swipe-to-go-back gesture: whether it can start, which views are entering and leaving, and whether the entering page ends up visible. These logs are off in every build, dev included. Ionic's `logLevel` config turns them on, either through the URL:
Copy file name to clipboardExpand all lines: docs/react-router/testing.md
+9Lines changed: 9 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,6 +42,15 @@ Useful flags:
42
42
|`--app <name>`| Pick a different app variant from `packages/react-router/test/apps/` (default: `reactrouter6-react18`; use `reactrouter6-react19` for the latest supported React version) |
43
43
|`--serve`| Start the dev server only and open the browser |
44
44
45
+
## Debug Logging in E2E Runs
46
+
47
+
The test app starts with `setupIonicReact({ logLevel: LogLevel.DEBUG })`, so the `StackManager` swipe-back diagnostics are on for every spec.
48
+
49
+
- Cypress prints the browser console to the terminal on failure, via `cypress-terminal-report`.
50
+
- Playwright records a trace on the first retry, so CI failures come with one. Open it with `npx playwright show-trace <path>` and read the console tab. Retries are off locally, so pass `--trace on` when you want the same thing from a local run. Don't turn tracing on by default: the recording overhead is enough to destabilize the tab lifecycle specs on React 19.
51
+
52
+
A passing run collects the same logs in the browser and throws them away, so nothing reaches your terminal. See [Debug Logging](./README.md#debug-logging) for turning them on in your own app.
53
+
45
54
## Test App Build Structure
46
55
47
56
Unlike other test applications, these test apps are broken up into multiple directories. These directories are then combined to create a single application. This allows us to share common application code, tests, etc so that each app is being tested the same way. Below details the different pieces that help create a single test application.
0 commit comments