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
Copy file name to clipboardExpand all lines: playwright/src/main/java/com/microsoft/playwright/Tracing.java
+18Lines changed: 18 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,12 @@
23
23
* API for collecting and saving Playwright traces. Playwright traces can be opened in <a
24
24
* href="https://playwright.dev/java/docs/trace-viewer">Trace Viewer</a> after Playwright script runs.
25
25
*
26
+
* <p> <strong>NOTE:</strong> You probably want to <a href="https://playwright.dev/docs/api/class-testoptions#test-options-trace">enable tracing in
27
+
* your config file</a> instead of using {@code context.tracing}.The {@code context.tracing} API captures browser operations and network activity, but it doesn't record test assertions
28
+
* (like {@code expect} calls). We recommend <a
29
+
* href="https://playwright.dev/docs/api/class-testoptions#test-options-trace">enabling tracing through Playwright Test
30
+
* configuration</a>, which includes those assertions and provides a more complete trace for debugging test failures.
31
+
*
26
32
* <p> Start recording a trace before performing actions. At the end, stop tracing and save it to a file.
27
33
* <pre>{@code
28
34
* Browser browser = chromium.launch();
@@ -200,6 +206,12 @@ public StopChunkOptions setPath(Path path) {
200
206
/**
201
207
* Start tracing.
202
208
*
209
+
* <p> <strong>NOTE:</strong> You probably want to <a href="https://playwright.dev/docs/api/class-testoptions#test-options-trace">enable tracing in
210
+
* your config file</a> instead of using {@code Tracing.start}.The {@code context.tracing} API captures browser operations and network activity, but it doesn't record test assertions
211
+
* (like {@code expect} calls). We recommend <a
212
+
* href="https://playwright.dev/docs/api/class-testoptions#test-options-trace">enabling tracing through Playwright Test
213
+
* configuration</a>, which includes those assertions and provides a more complete trace for debugging test failures.
* <p> <strong>NOTE:</strong> You probably want to <a href="https://playwright.dev/docs/api/class-testoptions#test-options-trace">enable tracing in
235
+
* your config file</a> instead of using {@code Tracing.start}.The {@code context.tracing} API captures browser operations and network activity, but it doesn't record test assertions
236
+
* (like {@code expect} calls). We recommend <a
237
+
* href="https://playwright.dev/docs/api/class-testoptions#test-options-trace">enabling tracing through Playwright Test
238
+
* configuration</a>, which includes those assertions and provides a more complete trace for debugging test failures.
0 commit comments