Skip to main content

Natural Language

Describe what you want to test in plain English. AI converts it to Playwright code. Example:
Test checkout flow:
1. Go to store.rehearsal.ai
2. Add green shirt to cart
3. Click checkout
4. Fill in shipping address
5. Verify order confirmation appears
What you get:
  • Clean TypeScript Playwright code
  • Proper expect() assertions
  • Comments explaining each step
  • Ready to run in CI/CD
Tests take 2-5 minutes to generate. Watch live execution in the dashboard.

Recording

Click record, use your app normally, get Playwright code. Steps:
  1. Dashboard → New Test → Record
  2. Perform actions in your app
  3. Click checkpoints to add assertions
  4. Stop recording → Code auto-generated
Best for:
  • Complex user flows
  • Apps with lots of interactions
  • Visual regression testing

Common Patterns

Navigate to app.example.com/login
Enter email: test@example.com
Enter password: testpass123
Click "Sign In"
Verify dashboard page loads
Go to contact form
Fill name: John Doe
Fill email: john@example.com
Fill message: Test message
Click submit
Verify "Thank you" message appears
Search for "laptop"
Click first result
Add to cart
Go to cart
Click checkout
Fill shipping info
Verify order total is correct

Tips

  • Be specific: “Click the blue ‘Submit’ button” > “Submit form”
  • Add assertions: Tell AI what to verify at each step
  • Break it up: Create separate tests for different flows
  • Use test suites: Group related tests together