Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save pablocattaneo/b8b03c85f519b0ee568338700bdc3795 to your computer and use it in GitHub Desktop.

Select an option

Save pablocattaneo/b8b03c85f519b0ee568338700bdc3795 to your computer and use it in GitHub Desktop.
// you can do that using the toBeVisible method of the object that returns expect method
import { test, expect } from '@playwright/test';
test('basic test', async ({ page }) => {
await page.goto('https://playwright.dev/');
const inputName = page.locator("#name") // Select element by id
await expect(inputName).toBeVisible()
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment