Skip to content

Commit 8c47f59

Browse files
authored
docs(csharp): fix nonexistent method names in guide examples (#42507)
Co-authored-by: Super-Eric <9334019+Super-Eric@users.noreply.github.com>
1 parent bd6e552 commit 8c47f59

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

‎docs/src/extensibility.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ button_count = page.locator("tag=button").count()
155155
```csharp
156156
// Register the engine. Selectors will be prefixed with "tag=".
157157
// The script is evaluated in the page context.
158-
await playwright.Selectors.Register("tag", new() {
158+
await playwright.Selectors.RegisterAsync("tag", new() {
159159
Script = @"
160160
// Must evaluate to a selector engine instance.
161161
{

‎docs/src/mock.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ await page.RouteAsync("*/**/api/v1/fruits", async route => {
7676
await page.GotoAsync("https://demo.playwright.dev/api-mocking");
7777

7878
// Assert that the Strawberry fruit is visible
79-
await Expect(page.GetByTextAsync("Strawberry")).ToBeVisibleAsync();
79+
await Expect(page.GetByText("Strawberry")).ToBeVisibleAsync();
8080
```
8181

8282
```java
@@ -188,7 +188,7 @@ await page.RouteAsync("*/**/api/v1/fruits", async (route) => {
188188
await page.GotoAsync("https://demo.playwright.dev/api-mocking");
189189

190190
// Assert that the Loquat fruit is visible
191-
await Expect(page.GetByTextAsync("Loquat", new () { Exact = true })).ToBeVisibleAsync();
191+
await Expect(page.GetByText("Loquat", new () { Exact = true })).ToBeVisibleAsync();
192192
```
193193

194194
```java

‎docs/src/navigations.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ page.wait_for_url("**/login")
147147

148148
```csharp
149149
await page.GetByText("Click me").ClickAsync();
150-
await page.WaitForURL("**/login");
150+
await page.WaitForURLAsync("**/login");
151151
```
152152

153153
## Back/Forward Cache (BFCache)

0 commit comments

Comments
 (0)