Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
docs: move note (#36432)
Patrik Csak56ccccddb883
diff --git a/docs/src/test-snapshots-js.md b/docs/src/test-snapshots-js.mdindex 6a8d42e886..5c64eccfbb 100644--- a/docs/src/test-snapshots-js.md+++ b/docs/src/test-snapshots-js.md@@ -50,6 +50,9 @@ The snapshot name `example-test-1-chromium-darwin.png` consists of a few parts:The snapshot name and path can be configured with [`property: TestConfig.snapshotPathTemplate`] in the playwright config.+> Note that `toHaveScreenshot()` also accepts an array of path segments to the snapshot file such as `expect().toHaveScreenshot(['relative', 'path', 'to', 'snapshot.png'])`.+> However, this path must stay within the snapshots directory for each test file (i.e. `a.spec.js-snapshots`), otherwise it will throw.+## Updating screenshotsSometimes you need to update the reference screenshot, for example when the page has changed. Do this with the `--update-snapshots` flag.@@ -58,9 +61,6 @@ Sometimes you need to update the reference screenshot, for example when the pagenpx playwright test --update-snapshots```-> Note that `snapshotName` also accepts an array of path segments to the snapshot file such as `expect().toHaveScreenshot(['relative', 'path', 'to', 'snapshot.png'])`.-> However, this path must stay within the snapshots directory for each test file (i.e. `a.spec.js-snapshots`), otherwise it will throw.-## Options### maxDiffPixels