Playwright error

Error: locator.selectOption: Element is not a <select> element

selectOption() only works on native <select> elements, but this locator matched a custom dropdown component instead.

Why this happens

How to fix it

  1. For custom dropdowns, click to open the menu, then click the option directly: `await page.getByRole('option', { name }).click()`