ExpertPW-EMP-00660 minutesPlaywright

Prove employee session isolation

Two independent Lab sessions must never observe each other’s synthetic employee changes.

  • api
  • isolation
  • authentication

Objective

What to automate

Create an employee in one header-mode Lab session, prove it is absent in another, then reset the first session.

Preconditions and test data

Preconditions

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

Test data

  • session A: emp-a
  • session B: emp-b

Expected result

Session B never contains Session A data and reset removes the overlay without affecting Session B.

Progressive hints

Hint 1

Create two explicit Lab session headers.

Hint 2

Use the CSRF token issued to each session for mutations.

Hint 3

Compare filtered responses before and after resetting only Session A.

I’ve tried it — show solution
  1. Create two explicit Lab session headers.
  2. Use the CSRF token issued to each session for mutations.
  3. Compare filtered responses before and after resetting only Session A.

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