BrauzerLab
← Back to missions 33 / 50

Operating on Multiple Elements

Medium ~180 sec

The notification list has two notifications, each with a Delete button. Your job is to click both buttons.

Clicking a single button is not enough. To act on all matching elements, select each one individually using .nth(), .first(), .last(), or use the .first() + .last() combination.

page is ready. Each button has its own id and data-testid — you can also target them directly.

Two valid approaches: .nth(0) + .nth(1), or .first() + .last(). Two separate clicks via direct id also work.

TASK

Iterate over all matching elements.

Provided for you
import { test, expect } from '@playwright/test';

test('Operating on Multiple Elements', async ({ page }) => {
  await page.goto('https://lab.local/mission/iterate-multiple');
  // ↓ Your code goes below ↓
});
Editor
https://lab.local/mission/iterate-multiple
Loading...
Results will appear here — press Run or Check.