Prerequisites
- Python 3.9+ (for backend)
- Node.js 18+ (for MCP server)
- Google Gemini API Key (for AI features)
- Android SDK and ADB (see Android Setup)
Backend Setup
The backend handles test orchestration and coordination using Google’s ADK.Step 1: Clone the Repository
Step 2: Set Up Python Environment
- macOS/Linux
- Windows
Step 3: Install Dependencies
Step 4: Configure Environment
Create a.env file in the backend directory:
- Go to Google AI Studio
- Click “Create API Key”
- Copy the key and paste into your
.envfile
Step 5: Start the Backend
MCP Server Setup
The MCP server acts as the interface between AI tools (Claude Code, Gemini CLI) and the backend.Step 1: Navigate to MCP Server Directory
From your OpenTester repository:Step 2: Install Dependencies
Step 3: Configure Backend URL
Create a.env file in the mcp-server directory:
Step 4: Start the MCP Server
For development with auto-reload:Connect Everything
Now you have both services running locally. Update your AI tool configuration to use the local backend.Claude Code
Edit your Claude Code MCP configuration to point to the local backend:Gemini CLI
Edit your Gemini CLI settings:Development Workflow
Testing Your Changes
Auto-reload
Both servers support auto-reload:
- Backend:
--reloadflag in uvicorn - MCP Server:
npm startwith nodemon
Common Development Commands
Backend:Debugging
Backend Logs
The backend logs are printed to the terminal. Look for:- Request/response messages
- API errors
- Python tracebacks
MCP Server Logs
The MCP server also logs to the terminal. Check for:- MCP tool calls
- Connection messages
- Error messages
Enable Verbose Logging
Backend:Database & State
The backend may use local storage or database files. By default, they’re stored in:backend/data/(for local files)- Or a local database like SQLite
Stopping Services
To stop the backend or MCP server:- Press
Ctrl+Cin the terminal where it’s running - Or kill the process by port (see “Common Development Commands” above)
Running in Production Mode
For testing how it would run in production: Backend:Using Docker (Optional)
If you prefer Docker: Backend:Troubleshooting
Port 8080 already in use
Port 8080 already in use
Another process is using the port. Kill it:Or use a different port:
GEMINI_API_KEY not set
GEMINI_API_KEY not set
Make sure your Or set it in your terminal:
.env file exists in the backend directory and has the key:ModuleNotFoundError in backend
ModuleNotFoundError in backend
Your Python virtual environment might not be active:Then try again.
MCP server can't connect to backend
MCP server can't connect to backend
Check that:
- Backend is running at
http://127.0.0.1:8080 BACKEND_URLenv var is set correctly in MCP server- No firewall is blocking localhost
- Check logs for connection errors
npm start fails
npm start fails
Make sure you’ve installed dependencies:And check your Node.js version:
Contributing
When contributing to OpenTester:- Create a feature branch
- Make your changes locally
- Test thoroughly using the local setup
- Commit and push to your fork
- Open a pull request
Need Help?
- Check GitHub Issues
- Review the main README
- Check the API Reference for tool documentation
