diff --git a/docs/src/api/class-locatorassertions.md b/docs/src/api/class-locatorassertions.md index 8f8233fae4..dfd65cdf76 100644 --- a/docs/src/api/class-locatorassertions.md +++ b/docs/src/api/class-locatorassertions.md @@ -2249,23 +2249,6 @@ Asserts that the target element matches the given [accessibility snapshot](../ar ```js await expect(page.locator('body')).toMatchAriaSnapshot(); -await expect(page.locator('body')).toMatchAriaSnapshot({ name: 'snapshot' }); -``` - -```python async -await expect(page.locator('body')).to_match_aria_snapshot(path='/path/to/snapshot.yml') -``` - -```python sync -expect(page.locator('body')).to_match_aria_snapshot(path='/path/to/snapshot.yml') -``` - -```csharp -await Expect(page.Locator("body")).ToMatchAriaSnapshotAsync(new { Path = "/path/to/snapshot.yml" }); -``` - -```java -assertThat(page.locator("body")).matchesAriaSnapshot(new LocatorAssertions.MatchesAriaSnapshotOptions().setPath("/path/to/snapshot.yml")); ``` ### option: LocatorAssertions.toMatchAriaSnapshot#2.name @@ -2276,6 +2259,12 @@ assertThat(page.locator("body")).matchesAriaSnapshot(new LocatorAssertions.Match Name of the snapshot to store in the snapshot (screenshot) folder corresponding to this test. Generates sequential names if not specified. +**Usage** + +```js +await expect(page.locator('body')).toMatchAriaSnapshot({ name: 'snapshot.yml' }); +``` + ### option: LocatorAssertions.toMatchAriaSnapshot#2.timeout = %%-js-assertions-timeout-%% * since: v1.50