The TestDriver VS Code extension is a powerful tool that integrates TestDriver’s AI-driven test generation capabilities directly into your development environment:
  • Get started with example scripts for different platforms
  • Get syntax highlighting and autocompletion for TestDriver YAML
  • Chat with the TestDriver agent to generate tests based on your requirements
  • Save and manage your tests directly within your project
  • Run and debug tests directly from the IDE
  • View test results and logs within the IDE
The TestDriver VS Code Extension is currently in beta. If you encounter any issues or have feedback, please let us know in Discord
1

Install the VS Code Extension

Click the button below to install the TestDriver extension for your preferred IDE. Then, follow the setup guide and chat with TestDriver to create your first test.
https://mintcdn.com/testdriver-ianjennings-self-hosted/Leg_GXbsT1mY6Sgd/images/content/extension/vscode.svg?fit=max&auto=format&n=Leg_GXbsT1mY6Sgd&q=85&s=76be0e526d1ab69dda39648107a185b3

VS Code

https://mintcdn.com/testdriver-ianjennings-self-hosted/Leg_GXbsT1mY6Sgd/images/content/extension/cursor.svg?fit=max&auto=format&n=Leg_GXbsT1mY6Sgd&q=85&s=818bb5ee26d104a9a4e268c1f377704d

Cursor

https://mintcdn.com/testdriver-ianjennings-self-hosted/Leg_GXbsT1mY6Sgd/images/content/extension/windsurf.svg?fit=max&auto=format&n=Leg_GXbsT1mY6Sgd&q=85&s=a7a75928416a6643dbfd0865905a2334

Windsurf

2

Set Your TestDriver API Key

After installing the extension, you’ll need to set your TestDriver API key in the extension settings.
  1. Open the command palette (Cmd+Shift+P or Ctrl+Shift+P).
  2. Search for “Preferences: Open Settings (UI)” and select it.
  3. In the search bar, type “TestDriver” to filter the settings.
  4. Find the “TestDriver: Set API Key” field and enter your API key from the TestDriver dashboard.
You can also set the TD_API_KEY environment variable in your system if you prefer not to enter it directly in the extension settings.
3

Choose a Platform

Click on the TestDriver icon in the sidebar to open the extension panel and choose a platform to get started (Web, Desktop, or Mobile).
4

Create Your First Test

Now chat with the TestDriver agent to create your first test! Describe what you want to test, and the agent will generate the test steps for you.
5

Run your test

Run your test by clicking the “Run” button in the extension panel. You can view the test results and logs directly within VS Code’s Test Explorer. Learn more about running tests in VS Code.

Pro Tip: Always start with interactive mode (testdriverai) to explore and refine your tests before saving them. It’s faster and more intuitive!