Watch it run
The test
click-icon.test.mjs
How it works
performLogin()is a plain function that takes the TestDriver instance, so any test can reuse it.- The demo store shows its password on screen, so
extract()reads it. type(password, { secret: true })keeps the password out of logs.focusApplication('Google Chrome')brings Chrome to the front before the test uses it.- The
find()description names the icon and its position (“next to the Cart text in the top right corner”). This helps the AI pick the right one.
Run it
The test is in the TestDriver SDK repository. Clone it, install dependencies, and run the file:TD_API_KEY. Create a key at console.testdriver.ai/team/api-keys. Then set it in your environment or a .env file.

