Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
TestDriver Test Runners are billed per minute they run.
All TestDriver Pro Plans start with $100 in free credits!
Price
Free
$0.05/minute
$0.08/minute
Support
Community
Email & Chat
White-Glove
Linux Sandbox
✅
✅
✅
✅
✅
✅
✅
Linux Runners
✅
✅
Windows Runners
✅
✅
Mac Runners
✅
✅
Follow the Local Agent Setup to run on your own machine for free. You'll use your own computer to create and run tests.
We recommend building and running your tests with our linuxGitHub Actions. You can run multiple tests in parallel and deploy them to CI/CD with our GitHub Action Setup.
If you're building a desktop app, need more coverage, more power, or want to test more complex flows, we recommend using our hosted Windows Runners.
TestDriver vs Playwright vs Selenium
TestDriver opeates a full desktop environment, so it can run any application.
Web Apps
Desktop Apps
Chrome Extensions
TestDriver is AI first.
Test Generation
Adaptive Testing
Visual Assertions
Self Healing
Application Switching
GitHub Actions
Team Dashboard
Team Collaboration
Testdriver has more coverage than selector based frameworks.
Browser Viewport
Browser App
Operating System
PDFs
File System
Push Notifications
Image Content
Video Content
<iframe>
<canvas>
<video>
Debugging features are powered by Dashcam.io.
AI Summary
Video Replay
Browser Logs
Desktop Logs
Network Requests
Team Dashboard
Team Collaboration
TestDriver is browser agnostic and supports any verson of any browser.
Chrome
Firefox
Webkit
IE
Edge
Opera
Safari
TestDriver currently supports Mac and Windows!
Windows
Mac
Linux
Instantly Generate and Deploy UI Tests
With TestDriver’s AI-powered QA Agents, creating and deploying robust UI tests has never been faster or easier. Here's how to get up and running in no time.
The fastest way to create your first set of tests is by running the demo. TestDriver will automatically log into your application, generate a dozen UI, and push them directly to your GitHub repository.
Follow the guide here to generate your first test suite.
Getting started with TestDriver is simple. Just download the TestDriver Agent to enable test generation directly from your environment.
Need Help? Watch the Setup Video
Follow along with our step-by-step YouTube setup guide to see how easy it is to install the agent, connect your app, and start generating tests—no guesswork needed.
To get started, install the testdriverai
package globally using Yarn. This package enables you to generate tests effortlessly using natural language commands.
Next, create a new directory for your test project and initialize it with testdriverai init.
This will launch the interactive setup process:
TestDriver Runners are the fastest way to get started, but you'll need an TestDriver Pro plan. See Getting an API Key.
Every TestDriver Pro plan comes with $100 of free credits
You can use your own computer as a runner for free. See Local Agent Setup
Subscribe to TestDriver Pro in the TestDriver Dashboard to access your API key. Every Pro plan comes with $100 of free credits to help you hit the ground running.
Paste your API key into the prompt when asked, then follow the remaining steps in the setup to complete your project configuration.
Now comes the fun part—building your tests! To get started, trigger the Computer-Use Agent by running:
This launches TestDriver in interactive mode. The agent will begin listening for commands and automatically generate test steps based on your input. All generated commands will be saved to testdriver/testdriver.yaml
Now, just tell TestDriver what you want it to do. For our example, try click new task
.
TestDriver will analyze your screen, interpret your instruction, and generate a full test script for you. It can see your UI, control the mouse and keyboard, and automate complex workflows—all through simple commands.
See the yml
TestDriver generated? That's our own schema. You can learn more about it in the Test Steps.
You can continue instructing TestDriver with natural commands. It will visually inspect your app and generate the next steps for you. Try:
If something didn't work, you can use /undo
to remove all of the test steps added since the last prompt.
Before pushing to GitHub, it’s a good idea to validate your test locally. After you’ve saved the test using /save
, run:
Ready to ship your tests? Check out our CI/CD integration guides to learn how to deploy tests to GitHub and automate them in your pipeline.
TestDriver Test Generation will explore your app and generate tests.
Test Generation works best with publicly accessible web apps.
TestDriver will crawl your app and generate tests. It interacts with each element and continues to come up with new ideas.
TestDriver can generate 1,000s of tests automatically. Tests are opened as Pull Requests. All you need ot do is review the created tests and merge them into your test suite!
The easiest way to generate tests for your app is to use the form below. This will generate up to 10 tests for you in a new GitHub repository.
TestDriver will generate tests for your app. Each pull request description will contain:
The test result
TestDriver may try multiple times to accomplish a goal.
Not every test will complete the objective entirely, but the steps that do complete successfully make great regression tests and it usually only takes a little modification to make a successful test!
We recommend:
Deleting the test steps that did not complete successfully.
You can clone this repository and run the tests locally using the TestDriver CLI.
This repository is set up to automatically run any merged regression tests! You'll need an API key to do so, and you can only get one by upgrading your account to Pro or higher.
Executes tasks based on user input using natural language processing. This command is invoked when the user input does not start with a /
command. The system interprets the input and attempts to carry out the task specified by the user.
This is the most common issues encountered with our agent, here are some possible reasons.
TestDriver uses the context from your prompt and the computer screen to make a decision of what commands to run. You should only prompt the AI to interact with elements it can currently see.
A common example of this is interacting with a dropdown. We often see users prompt the agent to interact with a dropdown and choose a state.
Instead, simply treat these as two separate prompts. This allows the UI to render and gives the AI the opportunity to parse the new screen data.
The TestDriver agent relies on visual understanding, not functional. Like any user, the AI does not understand what the function of a button will be. It can only guess.
If you're uncertain of how to describe an icon, simply ask ChatGPT-4o what it would call it, and use that as your input.
Small, isolated images smaller than 15x15px appear like "noise" to the AI and may not be clickable. However, you can use the match-image
command to select these using manually made screenshots.
The AI has trouble selecting some specific elements, like empty gray boxes, some substrings, or conditions where there is a lot of similar text close together.
The used to generate the test (description)
A video recording to review (with logs and network requests) on
The pull request will also contain a . Here is an example of a generated test
Click on the Dashcam preview to see a video of the AI completing the test as well as the AI logs, console logs, and network requests. For more on reviewing test results, see #.
Modifying the test steps if required. See for details on each TestDriver command
On've you've acquired an API key, create a named TESTDRIVER_API_KEY
and use the key as the value.
Read the guide for more information on integrating with GitHub.
Scan the to learn how to send emails and Slack notifications on test failures
Check out the for details on the high level commands TestDriver uses to generate tests or learn about regression tests in
Follow the guide to create and debug tests on your local machine
If that's the case, you can always fall back to . We've seen typically a test suite of 10 tests could require a single screenshot.
How to get a TestDriver API key.
Every TestDriver Pro plan comes with $100 in usage credits!
Deploying your TestDriver tests to CI/CD requires an API key!
Head over to https://app.testdriver.ai to get an API key
Upgrade your account to TestDriver Pro (Every upgrade comes with $100 in free usage credits!)
Copy the API key from your developer portal
Our team will build and deploy 30 tests in 30 days free!
We know our customers need QA coverage yesterday. While other QA services offer coverage delivered months later for hundreds of thousands of dollars, we'll set you for free during our 30-day trial!
Limited time offer! Don't miss your chance! Schedule an onboarding call now.
We think you're going to love TestDriver, which is why for a limited time our team will build 30 custom tests for you as a part of our risk-free, 30 day trail.
Afterward, plans start at just $995/m and include 12,000 runner minutes per month. That's enough minutes to run those 30 tests 2 - 5 times per day. See Promotion Details for more.
Test any publicly available desktop app, chrome extension, mobile app, or website
Choose from 250 AI generated tests within 7 days.
Run tests 3 - 5 times every day.
AI Quality reports delivered to your email.
AI fixes and maintains tests.
Integrates with GitHub.
Full access to our enterprise test dashboards
See Contract Details for more.
Book an Onboarding call so we can learn about the specific flows you want to test
We'll set up Generate a Test Suite to explore your app and generate 100s of tests.
Your new tests will be deployed to our GitHub Actions.
Our support will work with you to create tests for any features TestDriver might have missed.
Our support team will help train your engineers to create additional tests
Custom Onboarding
First 7 Days
AI Test Generation
First 7 Days
Instant coverage. We'll generate hundreds of tests for you to choose from.
Custom Test Creation
First 30 Days
Custom test scenarios. Our team will work with you to create tests for any features TestDriver might have missed.
Training
First 30 Days
Our support team trains your engineers on best practices for creating and maintaining TestDriver tests.
Test Execution
Recurring
Seamless deployment. Our hosted test runners execute your tests on a schedule or via GitHub Actins.
Get 30 custom tests free during a 30-day trial when subscribing to $995/m "30x30" plan
The tests are yours! You are free to modify, duplicate, or distribute tests however you wish
Payment method is required to begin trial
Contract renews monthly
Cancel any time, for any reason
Credits do not "roll over." Unused credits expire every month
Additional usage is billed at standard rates
TestDriver's local agent runs tests on your computer.
You can use your own computer as a TestDriver runner. TestDriver will 'alt-tab' between the terminal and your computer.
Just tell TestDriver what to test on your local machine and TestDriver will look at the screen, generate some commands to control the computer, and execute them.
Running tests on your own machine requires a bit of extra setup. You'll need to install some dependencies and give the terminal permission to see your screen and file system access.
Report issues to the testdriverai/testdriverai
repo
You'll need NodeJS version 20 to get started. Windows users will need a couple extra tools.
You will also need NodeJS if you don't have it yet.
Open a new terminal with admin privileges and execute the following command :
This gives TestDriver the right to execute it's scripts and is only valid for the current user.
You can install winget if you haven't already by downloading the App installer from Microsoft store.
Once its downloaded you need to add it to the system PATH environment variable. It's installed here:
Don't forget to replace it with your actual username.
Open a new terminal with admin privileges and execute the following command :
This gives TestDriver the right to execute it's scripts and is only valid for the current user.
Install testdriverai
via NPM. This will make testdriverai
available as a global command.
Run testdriverai init in a new folder.
This will walk you through setting up a local project.
Before we get started, let's set up your machine to collaborate with TestDriver.
TestDriver isn't like any framework you've used before. TestDriver makes decisions based on what it can see on your display!
TestDriver only knows about what it can see on your primary display!
For now, set up your environment with a browser window and your terminal side by side like so:
When you enter commands into TestDriver, the current terminal window will minimize and the focus-window
command will bring Chrome or other applications to the foreground.
The application you want to test should be visible before you run the testdriverai
command.
For our example, make a new incognito window in Chrome and load our test webpage:
Make sure to reset the test state!
Run tests on your local computer, sandbox, or on hosted runners.
CI/CD pipelines enhances software quality and release velocity. Adding TestDriver to your CI/CD, you can catch defects early, prevent regressions, and gain rapid feedback on code changes.
Our GitHub Action Setup allows you to run the tests you designed on your local computer in a virtual machine as part of your CI/CD workflow.
The TestDriver GitHub action will execute tests when you mention it in a comment, on a schedule, or anywhere else in your CI/CD workflow.
TestDriver can be integrated with GitHub Actions to automatically run tests whenever code is pushed to a repository. This ensures that new changes do not break existing functionality.
TestDriver can be configured to run specific test suites when a pull request is created. This ensures that any code changes meet the project's quality standards before being merged.
TestDriver can automatically generate and run test cases across multiple environments, providing detailed feedback on test coverage and potential issues.
Developers get immediate feedback on the success or failure of their changes within the pull request itself, reducing the time spent on manual code reviews.
You'll need a paid account to use the TestDriver GitHub action
In order to execute your TestDriver actions on our VMs you'll need to add your API key as a GitHub secret. If you don't see an API key, you'll need ot upgrade your account.
Now it's time to create your first TestDriver workflow.
In .github/workflows/testdriver.yml
add the following code.
If you used testdriverai init
to create your TestDriver project, these files will already be in your repository.
Notice that on line 23
we're invoking the agent. In this case we're using the /run
command to execute our file from our local directory.
You can also use commands like /explore
, use variables, or supply your prompts dynamically from earlier steps. A common workflow is wait for staging to deploy before executing the test.
The GitHub action is triggered via the conditions supplied via on
The key
value is used to authenticate you
An ephemeral virtual machine is spawn on our infrastructure
The code from the current branch will be cloned on to the VM
prompt
is parsed as a markdown list.
Each list item from promp
is fed into TestDriver one by one
TestDriver summarizes the test and sets it's exit code depending on it's pass or failed state
The VM is destroyed and all data is wiped
Save the file, make a new branch, push to your repository, and create a new pull request.
This will trigger a new TestDriver execution.
The best way to run tests twice as fast is to split them in half!
The, simply parallelize your test executions by calling the TestDriver action multiple time as a part of two different jobs.
Here's an example of testing a matrix of files.
How to provision the VM and build your app before running TestDriver
Prerun scripts are Bash commands executed on a TestDriver VM before each test within a CI/CD pipeline. Their primary purpose is to establish the state of a machine. This ensure it is consistent before every test execution.
You can configure prerun script to install necessary dependencies, build your application, set specific configurations, and more.
This crucial step helps to speed up the setup of an environment, prepare for a test suite to run, and prevent test failures due to environment inconsistencies and promote reproducible builds, ultimately enhancing the overall test suite's effectiveness.
This is an example of how to download Arc Browser and use it instead of Chrome.
How to change the operating system platform.
To configure the operating system, simply supply the os
param to the GitHub action. The current available operating systems are windows
and mac
.
Mac execution is only available to Enterprise customers.
Note that prerun files are executed on these machines themselves. You must use powershell
on Windows and bash
on mac.
Get set up quickly with custom workflows and developed by the TestDriver team.
TestDriver Cloud Testing is performed via . You can learn more by visiting the marketplace page.
Log in the team page in and .
Paste the API key as a named TESTDRIVER_API_KEY
See for output definitions and code samples.
begins recording
If supplied, the
ends recording
Rather than execute your tests sequentially, you can make use of the command to share common setup and teardown test plans.
The following example will run the same test using 4 different configurations by utilizing .
Quickly deploy AI QA tests.
Safeguard your most important user flows with generated tests.
Increase your total coverage
Test flows never possible before with our powerful computer-use agent.
Spend less time on maintenance
TestDriver tests automatically repair themselves.
windows
Windows Server 2022 Base 10
t2.large
64-bit (x86)
mac
MacOS Sanoma
mac1.metal
x86_64_mac
Optimize your tests to save serious time!
While TestDriver is incredibly smart, using AI matching methods all the time can be slow. Nobody wants to block developers from merging while waiting for tests to run!
Here are some tips for improving TestDriver performance.
Covered in the previous section, use runand Parallel Testing to split your actions into multiple files and run them.
ai
matching methodThe most common actions like hover-text,
wait-for-text
, and scroll-until-text
use an optimized matching algorithm.
This algorithm uses text similarity to quickly compute the most similar text to what appears in your yml
. This is about 40% faster than the ai
method!
The assert method has property async: true
which allows you to create non blocking test assertions costing you almost no time!
You can chain GitHub actions together to create awesome workflows.
The TestDriver action outputs the following variables. You can chain mlutliple actions together to post TestDriver results as comments, send an email on failure, or upload them to 3rd party test reporting software.
Output Variable
Description
summary
Contains the TestDriver AI text summary result of the action execution.
link
markdown
Contains the markdown-formatted shareable link. This includes a screenshot of the desktop!
success
Indicates whether the action passed successfully (true
or false
).
Here's an example of creating a comment on the PR after every execution.
Link to the Dashcam dash. See
In this section you will find example workflows for a variety of use cases
All the valid commands and their properties.
TestDriver will worry about generating and maintaining tests for the most part. However, if you'd like to edit tests or gain a better understanding of what's going on you can find all of the command
s in this secion.
As for YML format, here is an example of a valid yml
file:
Test multiple URLs in parallel
This workflow uses parallel testing to test several URLs in a short amount of time
This workflow:
Runs on each push to the "main" branch & every day at midnight
Defines a matrix of tests to be ran on individual, non-sequential, ephemeral VMs
Runs the matrix of tests
Each test in the matrix will have Dashcam installed, and Chrome opened to the respective URL defined in the URL value in the matrix
Debug your test executions with Dashcam!
Every TestDriver CI test is recorded with Dashcam, the first TestDriver product we built to help debug remote test executions.
Dashcam captures the video of the desktop test execution, the browser logs, network requests, prerun script output, and of course the TestDriver test execution. You can play it all back in the TestDriver dashboard!
Dashcam dashes are transmitted over HTTS, encrypted at test, and have "google style" sharing permissions. Sensitive data in logs is masked.
When a test finishes, a Dashcam clip (a dash for short) is into GitHub automatically. This enables developers to see a test artifact and collaborate directly from within GitHub.
You an learn more about Dashcam on the Dashcam documentation page.
Generate tests with natural language prompts.
This workflow will generate tests using the exploratory prompts found in the prompt
value of the GitHub Actionsconfiguration.
The prompt
value takes a markdown list as input.
Finds an image on the screen and performs an action (e.g., click or hover) at its center.
This command is useful for interacting with elements that the AI has trouble locating. The testdriverai
package will take a screenshot of the desktop and search for the location of the image within the screenshot.
Screenshot should be stored in testdriver/screenshots/(mac/linux/windows)/PATH.png
. TestDriver will dynamically resolve images based on the current platform.
The screenshot template matching logic looks for the most similar image within the screenshot and not exact matches. If the match is not above ~80%, it will search additional scales. Otherwise it fails
To create screenshots from remote tests, download the video of the test and open it "full" or "actual" size within your computer. Then use a screenshot tool like Cleanshot X to create a screenshot of the target element. Do the best you can to center the clickable element within the screenshot.
path
string
The path to the image file that needs to be matched on the screen. Do not include testdriver/screenshots/*/
action
string
The action to perform when the image is found. Available actions are: click
or hover
.The AI will click the center of the image.
Example Usage
> Click on 'options' and select 'edit'
> click on options
> select edit
> click on the "new task icon"
> click on the "plus icon"
Hovers over text matching the description. This can also handle clicking text.
text
string
The text to find on the screen. The longer and more unique, the better.
description
string
A description of the text and what it represents. The actual text itself should not be included here.
action
string
The action to take when the text is found. Available actions are: click
, right-click
, double-click
, hover
.
method
enum
The matching algorithm to use. Possible values are turbo
(default) and ai
.
Example Usage
Secrets can be passed into the workflow to not expose sensitive credentials
This workflow defines TD_USERNAME
and TD_PASSWORD
in env:
to existing repository secrets of the same name. These TD_USERNAME
and TD_PASSWORD
can then be used in any YAML passed into the workflow.
Secrets must begin with TD_
in order for Testdriver to be able to see them.
Example YAML steps using secrets could look like:
This workflow:
Runs on each push to the "main" branch & every day at midnight
Defines variables that point to repository secrets
Runs the test provided
Move the mouse to an image matching a description. This can also handle clicking.
description
string
A description of the image and what it represents. Do not include the image itself here.
action
string
The action to take when the image is found. Available actions are: click
, right-click
, double-click
, hover
.
Example Usage
Focuses an application by name.
name
string
The name of the application to focus.
Example Usage
Download a software installer and run it in a prerun script
This workflow's prerun script downloads an installer, then installs the software before running the tests
This workflow:
Runs on each push to the "main" branch & every day at midnight
Downloads an installer from the provided URL
Runs the installer and install the software
Run the provided test
Functionalities like 'automatic test matrix population' can be added to this workflow
TestDriver's Performance Agent alerts you of software quality issues and helps you identify the root cause.
The TestDriver Performance agent will email you weekly with high level summaries of your software quality. Get alerted of new bugs and detect feature regressions.
Every email includes:
an single performance score
a high level summary of test failures
test passing rates per test file
Also included is a high level summary of test passing rates and coverage by feature.
Measure test completion duration over time.
If the condition is true, runs the commands in the block. Otherwise, runs the commands in the else block.
condition
string
The condition to evaluate.
then
list of commands
The commands to run if the condition is true.
else
list of commands
The commands to run if the condition is false.
Example Usage
Types a keyboard combination.
keys
yml array of strings
A list of keys to press together.
Example Usage
Remembers a string value for later use.
Values are only remembered for a single session
description
string
The key of the memory value to store.
value
string
The value of the memory to store.
Example Usage
Embeds and runs another file within the current script. This is useful for reusing common sequences of commands or modularizing your scripts.
file
string
The path to the file to embed and run. Should be relative to the root of your git repo.
Example Usage
Automatically populate tests from a defined directory into the workflow
This workflow creates a matrix of tests dynamically based off of the YAML files available in a directory (in this case, and most, the /testdriver directory)
This workflow:
Runs on each push to the "main" branch & every day at midnight
Dynamically gathers .yml files from the /testdriver directory to create a matrix of tests
Runs the matrix of tests in parallel
Each test in the matrix will download the Arc browser installer
TestDriver is a next generation autonomous AI agent for end-to-end testing of web & desktop
TestDriver isn't like any test framework you've used before - it's more like your own QA employee with their own development environment.
Tell TestDriver what to do in natural language
TestDriver looks at the screen and uses mouse and keyboard emulation to accomplish the goal
TestDriver is "selectorless" testing. It doesn't use selectors or static analysis.
TestDriver then uses AI vision and hardware emulation to simulate real user on their own computer. This has three main advantages:
Easier set up: No need to add test IDs or craft complex selectors
Less Maintenance: Tests don't break when code changes
More Power: TestDriver can test any application and control any OS setting
Use our CLI to tell TestDriver what to do, like so:
As you can imagine, a specialized QA agent with it's own computer is extremely powerful. TestDriver can:
Test any user flow on any website in any browser
Clone, build, and test any desktop app
Render multiple browser windows and popups like 3rd party auth
Test <canvas>
, <iframe>
, and <video>
tags with ease
Use file selectors to upload files to the browser
Resize the browser
Test chrome extensions
Test integrations between applications
End-to-end is commonly described as the most expensive and time-consuming test method. Right now we write end-to-end tests using complex selectors that are tightly coupled with the code.
You've probably seen selectors like this:
This tight coupling means developers need to spend time to understand the codebase and maintain the tests every time the code changes. And code is always changing!
In end-to-end testing the business priority is usability. All that really matters is that the user can accomplish the goal.
TestDriver uses human language to define test requirements. Then our simulated software tester figures out how to accomplish those goals.
buy the 2nd product
These high level instructions are easier to create and maintain because they are loosely coupled from the codebase. We're describing a high level goal, not a low level interaction.
The tests will still continue to work even when the junior developer changes .product-card
to .product.card
or the designers change Add to Cart
to Buy Now
. The concepts remain the same so the AI will adapt.
TestDriver's AI is a fine tuned model developed over the course of more than a year with the help of computer vision experts, custom research tooling, and a few million dollars in funding (thanks VCs).
TestDriver uses a combination of reinforcement learning and computer vision. The context from successful text executions inform future executions. Here's an example of the context our model considers when locating a text match:
Prompt
Desired outcome
User Input
Screenshot
Image of computer desktop
Runtime
OCR
All possible text found on screen
Runtime
Text Similarity
Closely matching text
Runtime
Redraw
Visual difference between previous and current desktop screenshots
Runtime
Network
The current network activity compared to a baseline
Runtime
Execution History
Previous test steps
Runtime
System Information
Platform, Display Size, etc
Runtime
Mouse Position
X, Y coordinates of mouse
Runtime
Description
An elaborate description of the target element including it's position and function
Past Execution
Text
The exact text value clicked
Past Execution
How to securely store and use username, password, and other secrets within TestDriver
You'll likely want TestDriver to log in to your app as a test user, but you wouldn't want to expose that password to the world.
Thankfully TestDriver provides a way to securely use secrets. Secrets will be masked from all test output, including Debugging Test Runs logs.
Open your test file (.yml
) in a code editor and replace your secrets with ${TD_YOUR_SECRET}
.
TestDriver will only parse and mask secrets that begin with TD_
.
Here is an example of Test Stepswith the secret syntax.
First, configure the secrets within your GitHub repository.
Follow the guide here for detailed instructions on how to add a secrete to your GitHub repo or organization.
When using the GitHub Actions to spawn tests, supply your TD_SECRET
within the env:
value provided to the GitHub action.
Scrolls until the specified text is found on screen.
Example Usage
Types a string using keyboard emulation.
Example Usage
Waits until the specified image is seen on the screen.
Example Usage
Commands you can run in our interactive terminal
These are a list of commands you can run when you see the >
after running testdriverai
. Click any of the subpages to learn more. We recommend reading them in this order:
Waits until the specified text is seen on the screen.
Example Usage
Scrolls up or down using the mouse wheel.
Example Usage
Waits for a specified number of milliseconds before continuing.
Arguments
Example Usage
Asserts that the expectation is true using vision.
Example Usage
text
string
The text to find on screen. The longer and more unique, the better.
direction
string
Available directions are: up
, down
, left
, right
.
distance
number
How many pixels to scroll before giving up. Default is 1200
method
enum
The matching algorithm to use. Possible values are ai
(default) and turbo
.
string
string
The text string to type.
description
string
A description of the image.
timeout
number
How many milliseconds to wait for image to appear. Default is 5000
text
string
The text to find on the screen.
timeout
number
How many milliseconds to wait for text to appear. Default is 5000
method
enum
The matching algorithm to use. Possible values are ai
(default) and turbo
.
direction
string
Available directions are: up
, down
, left
, right
.
amount
number
Number of pixels to scroll
timeout
number
The duration in milliseconds to wait.
expect
string
The condition to check. This should be a string that describes what you see on the screen.
async
boolean
Should we continue without waiting for assertion to pass? async
assertions will still cause test failures. Default is false
Scrolls until the specified image is found.
Arguments
description
string
A description of the image and what it represents.
direction
string
Available directions are: up
, down
, left
, right
.
distance
number
How many pixels to scroll before giving up. Default is 1200
Example Usage
Ensure some criteria is true within your test.
Use the assert
to command generate an assertion. This will take a screenshot and use it to identify some criteria that ensures the task was complete.
This will "assert" that there's no error message, just like a user would see. The generated command will look like this:
When TestDriver runs this test, it will look at the screen and verify that the value of expect
is true
. If it is not true, the test will fail and exit immediately.
Many asserts can slow down a test. Use async: true
to speed things up.
Set up a local project.
Run the init
command to trigger the testdriverai interactive setup.
Launch the interactive agent
This is the core testdriver command that will launch the testdriver agent.
Supply a file command to specify output location
This defaults to testdriver/testdriver.yml
TestDriver will walk you through .env
customization and clone sample workflow files to deploy tests. See .
While open source, the TestDriver agent does send data to remote machines.
The TestDriver agent is open-source and available on NPM. You can browser the source and see all the data collected and how everything works.
The TestDriver agent does not contain any AI models within it. Instead, it uploads desktop context to our API which uses that context to make decisions about what actions to perform.
Our API makes use of OpenAI models behind the scenes. You can learn more about OpenAI and privacy in their privacy center.
During execution the TestDriver agent uploads the following information to our API
User input prompts
The active window and other windows that may be open (including application and window titles)
System information
The mouse position
Screenshots of the desktop
With the exception of desktop screenshots, desktop context is persisted into our database.
Desktop screenshots are uploaded to our server but are not persisted in our database.
TestDriver frequently takes screenshots of the desktop to provide our AI with decisions making context. You will not be prompted. Desktop screenshots are uploaded to our API for processing but are not persisted.
The TestDriver Agent will only take screenshots of the primary display. For complete privacy, we recommend running TestDriver within a virtual machine on your desktop.
TestDriver can not operate without visual context. Do not install TestDriver if you do not want to capture images of the desktop.
Information about the open windows on the desktop is reported by the active-window module.
Information about the computer system running testdriver is reported by the systeminformation module.
The prompts you input to TestDriver are uploaded to our API and persisted in a database. We store this data to provide our AI with a history of context.
When running testdriver init
you'll be asked if you'd like to share additional analytics. Sharing usage analytics is opt-in, this extra data will not be collected unless explicitly set in your environment.
If you would like to disable additional analytics, you can set TD_ANALYTICS
within your environment.
While the TestDriver Agent is free, we do reserve the right to rate limit or restrict usage by IP address for any reason.
/generate
will look at the display and generate lists of exploratory prompts that can be used to generate tests. Each exploratory test looks like a simple markdown file with a list inside.
Check out this test-search-function.md
for example:
TestDriver will generate 10 of these files every time the /generate
command is called. The files will be stored in ./testdriver/generate/*.md
.
Saves the current state of the test script to a file.
This command generates a YAML file with the history of executed commands and tasks.
Run a test from a file.
To run a test you've previously created, use the /run
command.
TestDriver will run the test plan back performing each command.
This command will exit the program upon execution. Any failures will be output and the program will exit with code 1
.
Generate is a experimental feature that instructs testdriverai
to come up with it's own ! The /generate
command is used in our demo.
The best way to use the /generate
command is to generate regression tests using .
Every test will be run in , and can be merged into a regression test!
Remove the last generated command.
If Testdriver doesn't do what you expect, you can easily remove newly generated commands with the /undo
. You can undo as many times as you like.
For example given the following test:
Calling /undo
will cause the last part to be undone and look like this:
Run a test file.
Runs the specified file.
The command will return exit code 0
if the test is successful and 1
if a failure.
Security and privacy in the TestDriver web UI.
Tests that execute via our GitHub Action are recorded and reported via Dashcam (another application developed by TestDriver). You can find more information on the Dashcam docs.
Dashcam and TestDriver share the same API and web application back end. This web application includes the following privacy and security features:
SSL
All data is transmitted over HTTPS
OAuth
Users may only authenticate via OAuth provided by Auth0
Team Management
Individual team members may be added or removed by administrators only.
Roll Based Access Control
The first user to create a team is the administrator. Administrators are the only users who can see the API key and manage team settings. Administrators can not be removed. All other users are normal members.
API Key Rotation
The team API key can be rotated. We recommend rotating your API key every 90 days.
Secret Masking
Test replay logs and network requests are parsed for secrets like credit card numbers, emails, passwords, and other keys. Found secrets are overwritten with asterisks ****
Encrypted At Rest
Test replays and logs are stored securely on Amazon S3 and encrypted at rest. Test results are are only available via temporary signed urls. Signed URLs are only generated for team users.
The TestDriver action is open source. You can find the source below.
TestDriver tests are executed on private virtual machines managed by Amazon EC2. These VMs are ephemeral meaning they only exist for the lifetime of the test execution. After the test completes, the VM is destroyed and the hard disk is wiped.
We recommend storing any private information as a secret in your GitHub repository. Learn more about storing secrets here.
Any secrets supplied within Prerun Scripts or prompts will be transmitted over SSL to our API. Secrets supplied to agent prompts will be persisted (see Agent), but prerun scripts are not persisted.
If your workflow is blocked by secret sharing, please contact us.
A common workflow is to use Prerun Scripts to access a private staging website via basic auth. This will allow you to securely log into staging without persisting sensitive data on our servers.
Testing production is the best starting point!
Testing production resources does not require any private information from your team. Simply provide the tests to TestDriver and point toward your publicly available endpoints. TestDriver does not need access to any private information.
Depending on your implementation, TestDriver may need secure information to test staging environments. See Secretsabove for more information on securely implementing tests on staging.
TestDriver can clone feature branches and build code on it's virtual machines using a similar workflow to GitHub runners.
In order for TestDriver to test development branches of private codebases, it's necessary to supply a GitHub Token within the GitHub action. This personal access token is used to clone the codebase on the VM.
This token is transmitted over SSL and is not persisted. Learn more about managing the privacy of GitHub access tokens here.
If you're on mac, you might see an error related to "screen capture permissions" when getting started. This means that the application invoking the `testdriverai` command does not have permission to capture.
This might be a little confusing at first. It's not testdriverai
that needs the permissions, it's the terminal or IDE that's calling testdriverai
that needs them. This is probably:
Mac Terminal
iTerm
VS Code
Or something similar
To enable screen capture permissions, do the following.
Open System Settings (or System Preferences on older versions).
Navigate to Privacy & Security > Screen Recording.
Find and enable permissions for Terminal (or any terminal-based app like iTerm2, if you're using it).
If the desired application is unavailable in the list, click on "+" symbol below, you will get a finder pop up, here find the app that you are currently using under Application section and click on open.
You may need to restart the terminal for the changes to take effect.