Commands Reference
Explore the available commands and their parameters.
Locate the Test File
TestDriver test files are typically stored in thetestdriver/
directory of your project. The default file is testdriver/testdriver.yaml
.
Open the Test File
Use your preferred text editor or IDE (for example, Visual Studio Code) to open the YAML file.YAML Structure
Each test file consists of:- Version: Specifies the TestDriver version that was used to generate the test file. This is used to lock the version of TestDriver that is used to run the test.
- Session: A unique identifier for the test session.
- Steps: A list of prompts and commands to execute.
test-file.yaml
The
version
captured when you generate a test file is the version of
TestDriver you used, and isnβt used when running the test. This doesnβt affect
your ability to use newer versions of TestDriver on existing test files nor do
these need to be updated when migrating to a new version.Modify the test steps
You can add, edit, or remove steps as needed. Each step contains:- Prompt: A description of the action.
- Commands: The specific actions to perform. It is an optional field, meaning, if there are no
commands
the AI considers theprompt
and generates and executes the yaml on-the-go using the exploratory mode
Example edits:
-
Add a Wait Command:
-
Change the URL:
Update the
text
field in thetype
command:
Validate the YAML syntax
Ensure the YAML file is properly formatted:- Use consistent indentation (2 spaces recommended).
- Avoid trailing spaces or tabs.
- TestDriver will validate the yaml syntax and provide suggestions to fix any errors when you run the test.
It is recommended to use our VS Code extension
while you are editing the yaml. It will provide you with a rich experience
with auto-completion, syntax highlighting, and validation.