Choosing a Model (Gemini)
Testronaut supports Google Gemini 2.5 models for agentic (tool-using) workflows.
You can select a Gemini model during testronaut --init, store it in testronaut-config.json, or override it per run via CLI or environment variables.
Heads-up: Gemini model access and rate limits depend on your Google Cloud or MakerSuite account.
If you select a model your account doesnโt have access to, the API will respond with a404orPERMISSION_DENIEDerror.
Supported Gemini model familiesโ
All of the following are compatible with Testronautโs tool calling & DOM agent features:
- Gemini 2.5 Pro โ High-quality, balanced model for reasoning and code
- Gemini 2.5 Flash โ Fast, low-latency model optimized for throughput
- Gemini 2.5 Flash-8B โ Lightweight Flash variant for cost efficiency
These identifiers map directly to Googleโs Generative Language API model IDs (e.g.,
gemini-2.5-pro).
Testronaut forwards your chosen ID directly to the API.
How Testronaut decides which model to useโ
-
CLI override (highest precedence)
npx testronaut --model gemini-2.5-pro -
Environment override
export TESTRONAUT_MODEL=gemini-2.5-flash -
Project config
Stored in yourtestronaut-config.jsonafter initialization. -
Fallback
Defaults togemini-2.5-flashif none are specified.
The active provider/model appear in:
- CLI JSON and HTML reports (
results.llm.provider&results.llm.model) - The Mission Control companion app (header and table pills)
Example configurationโ
{
"initialized": true,
"provider": "gemini",
"model": "gemini-2.5-flash",
"outputDir": "missions/mission_reports",
"projectName": "your-project",
"maxTurns": 20
}
Override per run:
npx testronaut checkoutFlow.mission.js --model gemini-2.5-pro
Or for CI/CD or temporary overrides:
TESTRONAUT_MODEL=gemini-2.5-flash-8b npx testronaut
Cost / performance guide (quick picks)
| Model | Strengths | Typical Use | Trade-offs |
|---|---|---|---|
| Gemini 2.5 Pro | Strong reasoning and comprehension | Complex workflows, DOM reasoning, deeper analysis | Slower, higher cost |
| Gemini 2.5 Flash | Very fast, low latency | Iterative development, large suites, smoke tests | Slightly shallower reasoning |
| Gemini 2.5 Flash-8B | Lightweight, cost-effective | Budget-conscious or parallel testing | Less capable in nuanced reasoning |
Recommendationsโ
Fast & low cost: gemini-2.5-flash
Best general agent: gemini-2.5-pro
High concurrency (CI): gemini-2.5-flash-8b
Rate limits & backoffโ
Testronaut applies token-aware throttling and will automatically back off if you approach your per-minute token limits.
Unlike OpenAI, Geminiโs rate limits may not always be returned in headers โ Testronaut uses conservative defaults and runtime heuristics to avoid throttling errors.
Troubleshootingโ
โ404: model not foundโ
You may not have access to that Gemini model.
Check the available models under your API key or try switching to gemini-2.5-flash.
โ429: rate limit exceededโ
Try using gemini-2.5-flash or gemini-2.5-flash-8b for high-volume or concurrent runs.
Model not listed?
Testronaut forwards model IDs directly, so newer releases (e.g. gemini-3.0) will work as long as they follow the same API schema.
Reports
Testronautโs JSON and HTML reports include:
llm.provider:"gemini"llm.model: e.g."gemini-2.5-flash"
The Mission Control dashboard displays these as colored pills in the report tables.