← Pause and Practice

PART 4 · LEGACY TRANSFORMATION · 15–20 MINUTES

Keep the intent.
Leave the brittle script.

Choose a legacy test, give it to your AI coding agent, and recover the business goal in the OpenTest.ai test-case format. These are synthetic legacy fixtures to convert—not scripts promised to run against the current shop.

1. Choose your legacy input

What must survive?

One vanilla latte. Medium size. Quantity one. The legacy fixture’s $4.50 total. A confirmed synthetic order.

Preserve those assertions. A CSS selector, fixed sleep, or button position is an implementation detail—not the goal.

Selectors → meaning#latte-vanilla becomes “choose a vanilla latte.”
Assertions → outcomesKeep item, size, quantity, total, and confirmation.
Waits → observed stateVerify readiness instead of preserving a fixed sleep.

2. Ask your coding agent to convert it

> Convert this legacy test into an OpenTest.ai intent-based test case. Preserve its business assertions, not its selectors.

The copied prompt includes the selected source, the format fields, and conversion instructions. No AI runs inside this page.

Inspect the full prompt before copying

Format reference: OpenTest.ai otai/testcase v1 ↗. The lesson uses its documented title, goal, and optional steps fields.

3. Inspect the result, then try the intent

Paste your agent’s JSON below, or reveal a prepared example for comparison. Review each original assertion before executing against an approved synthetic environment.

Next: ask your agent to execute the reviewed intent against TestBucks. Compare expected and observed results. Use simulated payments only; report mismatches instead of changing the test to pass.