Appearance
Commands
BugTrail has two commands you type in a terminal. Everything else is done in the browser extension.
What is a terminal?
A text window where you type commands: Terminal on Mac, PowerShell on Windows. You only need it for the two commands below.
Replay a recording
Plays a saved recording in a fresh browser and tells you whether every step worked.
text
node bin/replay.js recording.jsonReplace recording.json with the file you saved from the extension. Add any of the options below after it.
| Option | What it does | When to use it |
|---|---|---|
--headed | Shows the browser window while it replays | To watch what happens |
--continue | Keeps going after a step fails | To see every failure, not just the first |
--html report.html | Saves a report you can open in a browser | To share results with people |
--junit report.xml | Saves a report in the format test tools read | To feed CI or a test-management tool |
--csv report.csv | Saves a spreadsheet of the steps | To open in Excel or Sheets |
--json | Prints the full result as data | For other programs, not for people |
--jira | Files a Jira bug if the replay fails | See File Jira bugs automatically |
Result: the command finishes with code 0 when every step passed. Any other code means something failed, which is how automated systems know to raise an alarm.
Example: watch the replay and save a report.
text
node bin/replay.js recording.json --headed --html report.htmlGenerate a test script
Turns a recording into a test script you can keep and run again.
text
node bin/generate.js recording.json --out my-test.spec.js| Option | What it does | When to use it |
|---|---|---|
--out my-test.spec.js | Saves the script to this file. Without it, the script is shown on screen | Almost always |
--with-session | Includes your saved login in the script | Only if the flow needs you logged in. Treat the file like a password |
More in Generate a test script.