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(input): use web-first assertion for isChecked() (#28162)
Max Schmitt30aa8cd904bb
diff --git a/docs/src/input.md b/docs/src/input.mdindex 1569dbd31d..f340e03f48 100644--- a/docs/src/input.md+++ b/docs/src/input.md@@ -90,7 +90,7 @@ Using [`method: Locator.setChecked`] is the easiest way to check and uncheck a cawait page.getByLabel('I agree to the terms above').check();// Assert the checked state-expect(await page.getByLabel('Subscribe to newsletter').isChecked()).toBeTruthy();+expect(page.getByLabel('Subscribe to newsletter')).toBeChecked();// Select the radio buttonawait page.getByLabel('XL').check();@@ -101,7 +101,7 @@ await page.getByLabel('XL').check();page.getByLabel("I agree to the terms above").check();// Assert the checked state-assertTrue(page.getByLabel("Subscribe to newsletter").isChecked());+assertTrue(page.getByLabel("Subscribe to newsletter")).isChecked();// Select the radio buttonpage.getByLabel("XL").check();@@ -112,7 +112,7 @@ page.getByLabel("XL").check();await page.get_by_label('I agree to the terms above').check()# Assert the checked state-assert await page.get_by_label('Subscribe to newsletter').is_checked() is True+await expect(page.get_by_label('Subscribe to newsletter')).to_be_checked()# Select the radio buttonawait page.get_by_label('XL').check()@@ -123,7 +123,7 @@ await page.get_by_label('XL').check()page.get_by_label('I agree to the terms above').check()# Assert the checked state-assert page.get_by_label('Subscribe to newsletter').is_checked() is True+expect(page.get_by_label('Subscribe to newsletter')).to_be_checked()# Select the radio buttonpage.get_by_label('XL').check()@@ -134,7 +134,7 @@ page.get_by_label('XL').check()await page.GetByLabel("I agree to the terms above").CheckAsync();// Assert the checked state-Assert.True(await page.GetByLabel("Subscribe to newsletter").IsCheckedAsync());+await Expect(page.GetByLabel("Subscribe to newsletter")).ToBeCheckedAsync();// Select the radio buttonawait page.GetByLabel("XL").CheckAsync();