Read Generated Output
Review generated feature files, Playwright code, screenshots, traces, and project output before running tests.
Last updated
Was this helpful?
Review generated feature files, Playwright code, screenshots, traces, and project output before running tests.
After generation succeeds, review the output before you rely on the test.
The goal is to confirm that generated code matches the intended user behavior and is ready for a first run.
Feature file
The Gherkin still describes the behavior you intended.
Playwright code
The generated code follows the right journey and checks the expected result.
Generated path
The file was saved where you expect in your project.
Screenshots
The browser saw the right page or state during generation.
Trace
The agent's browser actions make sense when a trace is available.
Generation summary
No warnings or missing setup are called out.
What the Assistant learned
If present, this card lists app-specific behavior the agent discovered while exploring — read it to understand why the test is built the way it is.
Start with the Gherkin. If the feature intent is wrong, the generated code will usually be wrong too.
Check:
the feature name is clear
scenarios are focused
setup belongs in Background only when all scenarios need it
every scenario has a visible expected result
test data is repeatable
See Write good test instructions.
Generated Playwright code should:
Open the intended page
The test starts from the right target.
Use readable locators
The code can survive small layout changes.
Include assertions
The test proves the expected result, not just clicks around.
Avoid accidental private data
Credentials and secrets should come from safe setup.
Match the feature
Code and Gherkin should tell the same story.
You do not need to understand every line before the first run, but you should catch obvious wrong turns.
Screenshots and traces help explain what happened during generation:
Screenshot
Did the agent reach the expected page?
Trace
What did the browser do step by step?
Verification video
What did the final end-to-end verification look like?
Run details link
Did the run report setup or permission issues?
A completed generation now includes a trace you can open in the built-in Playwright trace viewer — whether the final verification passed or failed — alongside the verification video. Open the trace to step through the browser actions the assistant recorded and confirm they match the intended journey.
If the preview shows the wrong screen, improve the Gherkin or site setup before running a large suite.
Run the generated test when:
the feature describes the right behavior
the generated code appears to follow the feature
the target site and configuration are correct
required secrets and test data are available
the expected result is clearly asserted
Start with one test. See Run one test.
Gherkin is vague
Edit the feature and regenerate.
Generated code is close
Edit code or improve the specific Gherkin step.
The wrong page was used
Check the site URL and starting context.
Required data is missing
Add setup steps, prerequisites, or secrets.
Generation failed halfway
Review failure details before retrying.
For another pass, see Regenerate a test.
Last updated
Was this helpful?
Was this helpful?
