taqwright

Generating tests

Don't hand-write locators — pick them. The taqwright inspector is a browser-based device viewer that ranks candidate selectors against the live screen, and codegen is the same inspector with recording on, emitting a runnable spec as you drive the app.

Inspector & codegen

The inspector is a browser-based device viewer + locator picker. Run:

npx taqwright codegen

It boots a local server (default port 5274) and opens your browser. From the inspector you can:

Codegen

Codegen is the same inspector with recording on by default:

npx taqwright codegen

Every action you perform appends a line of taqwright source to the generated spec, which you can copy out as a runnable test. The emitted file is a full import { test, expect } from 'taqwright'; test('recorded test', …) spec — drop it under tests/ and npx taqwright test runs it as-is.

Debug a live test

Use the inspector to debug a live test. Drop await mobile.pause() mid-test. When the test hits that line, the inspector attaches to the running WebDriver session (no new Appium boot), opens in your browser, and the test resumes when you click Resume in the UI. Set PWDEBUG=0 to make pause() a no-op in CI without removing it.

This is the interactive counterpart to post-mortem tracing — pause when you want to poke at a stuck step by hand, trace when you want the whole timeline after the fact.