Prerequisites
Before you begin, you’ll need:- GitHub Copilot — A subscription with MCP access. A free tier is available.
- TestDriver Account — Create a free account at console.testdriver.ai to get your API key. 60 free device minutes, no credit card required.
- VS Code — The TestDriver extension provides the best experience with live preview and integrated test running.
Setup Steps
Install the TestDriver Extension
Install TestDriver for VS Code
- One-click sign-in and project initialization
- Live preview panel for watching tests execute
- MCP server configuration
Sign Into TestDriver
Sign in to connect your account and API key.
- Open the command palette (
Cmd+Shift+PorCtrl+Shift+P) - Run TestDriver: Login
- Your browser will open to the TestDriver sign-in page
- Sign in (or create an account)
- You’ll be redirected back to VS Code, now signed in
Initialize Your Project
Set up TestDriver in your project with a single command.
- Open the command palette (
Cmd+Shift+PorCtrl+Shift+P) - Run TestDriver: Init Project
- Creates a
package.jsonwith TestDriver and Vitest dependencies - Generates a
vitest.config.mjswith proper timeout settings - Creates example test files in
tests/ - Sets up
.envwith your API key - Creates the TestDriver agent file at
.github/agents/testdriver.agent.md - Configures the MCP server
If you already have a
package.json, the command will add the necessary dependencies to it.Start the MCP Server
The MCP server enables GitHub Copilot to control TestDriver sandboxes.After initialization, the MCP configuration is created at To start the MCP server:
.vscode/mcp.json:.vscode/mcp.json
- Open the command palette (
Cmd+Shift+PorCtrl+Shift+P) - Run MCP: List Servers
- Click on the testdriver server
- Select Start Server
Install Vitest Extension (Recommended)
For the best experience running tests, install the Vitest extension:After installation, you’ll see a beaker icon in the sidebar for accessing the Test Explorer.
Vitest Extension
Run tests with GUI mode from the Test Explorer
Verify Your Setup
To verify everything is configured correctly:- Open the command palette and run TestDriver: Check Status
- You should see:
- ✅ Signed in
- ✅ MCP server configured
- ✅ Project initialized
The Agent File
During initialization, TestDriver creates an agent file at.github/agents/testdriver.agent.md. This file tells GitHub Copilot how to use TestDriver’s MCP tools.
The agent has access to tools like:
session_start— Launch a sandbox with Chrome or other appsfind/click/type— Interact with elements on screenassert— Verify conditions using AI visionscreenshot— Capture the current screen state

