BeginnerPW-BKG-00115 minutesPlaywright

Find an available synthetic hotel room

A traveller needs an assertion-ready room result without relying on a real supplier.

  • locators
  • forms
  • dates

Objective

What to automate

Choose a destination and valid dates, then assert a visible available room and rate.

Preconditions and test data

Preconditions

  • Use a fresh isolated Practice Lab browser context.
  • Open the fixture identified by FX-BKG-001.

Test data

  • destination: Mumbai
  • check-in: 2026-11-12
  • check-out: 2026-11-14

Expected result

A visible room card shows a synthetic hotel, rate plan, and two-night total.

Progressive hints

Hint 1

Start from the Hotel and travel booking fixture.

Hint 2

Use the labelled Destination, Check-in, and Check-out controls.

Hint 3

Scope the assertion to the room results section.

I’ve tried it — show solution
  1. Start from the Hotel and travel booking fixture.
  2. Use the labelled Destination, Check-in, and Check-out controls.
  3. Scope the assertion to the room results section.

The deliberately failing starter is in tests/travel-booking.spec.ts inside the TypeScript starter ZIP.