Antigravity Test Orchestration
Antigravity Test Orchestration
Instructions
Use Google Antigravity as the autonomous test execution layer in the ITI three-lane toolchain (Cursor for development, Claude Code for context management, Antigravity for test/debug). Antigravity agents plan, execute, and verify test suites with browser automation, screenshot capture, and structured Walkthrough artifacts.
Prerequisites:
- Antigravity installed (v1.18.0+ required for browser sub-agent; ITI pins v1.107.0)
- Gemini 3 Pro (or 3.1 Pro) selected as the primary model — avoid flash-tier models for test orchestration
.agents/directory configured at project root with rules, skills, and workflows- Local dev environment running (WordPress dev server, Tauri dev build, Python venv, or Docker stack)
- Artifact Review Policy set to “Request Review” (never “Always Proceed”)
- Terminal Command Auto Execution set to “Request Review”
Agent dispatch for test execution:
Open the target project as a dedicated Antigravity workspace (never multi-root across clients). In the Agent Manager, click +Task and set Planning Mode to Plan for all non-trivial test sessions.
Standard test dispatch prompt:
/iti-delivery-framework
Run the existing test suite for [plugin/feature name].
Identify all failures, trace root causes to specific functions or files.
Generate a Walkthrough artifact that includes:
1. Test results summary (pass/fail counts)
2. Root cause analysis for each failure
3. Proposed fixes as diffs — do NOT apply them yet
4. Any [CONTEXT-UPDATE] flags for findings that should update CLAUDE.md
Do not modify source files.
Planning mode vs Fast mode:
| Mode | When to use | Trade-off |
|---|---|---|
| Plan | Test suites, multi-step QA, regression testing | Agent produces a reviewable plan before executing; slower but safer |
| Fast | Trivial checks (single file lint, quick lookup) | Immediate execution; no plan artifact to review |
Always use Plan mode when the test session could modify files, run terminal commands, or navigate a browser.
Workspace isolation rules:
- Each client project = a separate Antigravity workspace
- Never open a multi-root workspace spanning two clients
- Name workspaces explicitly:
[Client] / [Project] - Before each session: confirm the workspace name in Agent Manager matches the project
AGENTS.md configuration for test sessions:
The .agents/ directory at project root provides persistent context:
.agents/
├── rules/
│ ├── iti-context-system.md # Always-on: project context, protected files, available skills
│ └── test-session-rules.md # Manual: activated for diagnostic sessions
├── skills/
│ ├── iti-context.md # /iti-context — master ITI operating context
│ ├── iti-delivery-framework.md # /iti-delivery-framework — delivery phase reference
│ ├── iti-claude-context.md # /iti-claude-context — CLAUDE.md system context
│ └── iti-audit.md # /iti-audit — codebase accuracy audit
└── workflows/
├── test-session.md # /test-session — run test suite diagnostics
├── browser-test.md # /browser-test — browser-based UI testing
└── prompt-library.md # /prompt-library — quick reference for all workflows
Global rules live at ~/.gemini/GEMINI.md. GEMINI.md takes priority over AGENTS.md when both exist.
Artifact review protocol:
After an agent completes a test session, it produces a Walkthrough artifact containing:
- Test results summary (pass/fail/skip counts)
- Root cause analysis for each failure with severity classification
[PROPOSED-FIX]blocks with diffs — review before accepting[CONTEXT-UPDATE]flags for findings that should update CLAUDE.md- Browser session recordings and screenshots (for browser-based tests)
Review checklist for each artifact:
- [ ] Change is limited to the file/function the agent was asked about
- [ ] No changes to CLAUDE.md,
.cursorrules, or context markdown files - [ ] No new dependencies added without explicit approval
- [ ] No hardcoded credentials or environment-specific values
- [ ] WordPress security conventions preserved (nonces,
prepare(), output escaping) - [ ] For Tauri/Rust: no
unwrap()on user-facing paths, no hardcoded file paths
Test result triage:
| Status | Action |
|---|---|
| Pass | No action; verify count matches expectations |
| Fail — known issue | Confirm root cause matches known pattern; document if new variant |
| Fail — new issue | Create [PROPOSED-FIX] diff; classify severity; flag [CONTEXT-UPDATE] if architectural |
| Skip | Verify skip condition is intentional (missing fixture, env constraint) |
| Timeout | For heavy multi-agent workflows (>15s), timeouts confirm processing, not breakage |
Parallel agent dispatch:
The Agent Manager supports multiple concurrent agents across workspaces. Use this for:
- Running unit tests in one agent while browser QA runs in another
- Testing multiple product endpoints simultaneously
- Running regression suites on different feature branches
Each agent operates in its own context — ensure workspace isolation rules are followed.
CI/CD integration patterns:
Antigravity test sessions can feed into CI pipelines:
- Agent generates test results as structured Walkthrough artifacts
- Export screenshots and recordings from the Artifacts panel
- Commit test evidence alongside code changes
- Reference artifact IDs in PR descriptions for reviewability
For GitHub Actions integration, configure the browser sub-agent with headless mode and screenshot-on-failure: true in .agents/rules/.
Knowledge sync after test sessions:
Every Antigravity test session ends with knowledge sync (non-negotiable):
- Scan all Walkthrough artifacts for
[CONTEXT-UPDATE]flags - Classify each flag by tier: GLOBAL, PROJECT, PRODUCT, CLIENT, or MANUAL
- Switch to Claude Code to apply approved updates to the appropriate CLAUDE.md
- Commit knowledge updates separately from code fixes:
docs: sync knowledge files from Antigravity session YYYY-MM-DD
See operations/documentation/antigravity-runbook.md for the complete step-by-step protocol.
Hard boundaries — Antigravity must never:
- Modify CLAUDE.md at any tier
- Modify
.cursorrulesor.cursor/rules/*.mdc - Run
git push,git commit, orgit merge - Run database migrations without explicit human approval
- Access external URLs outside the local dev domain during browser testing
- Install packages without human review
Cross-references:
operations/documentation/antigravity-runbook.md— complete operational runbookoperations/documentation/claude-code-workflow.md— three-lane toolchain modeltest-plan-writingskill — test plan structure and coverage requirementssession-context-protocolskill — session opener/closer lifecycleantigravity-debuggingskill — parallel debug dispatch patternsantigravity-browser-qaskill — browser sub-agent QA workflows
Outputs: Walkthrough artifacts with test results, root cause analyses, proposed fix diffs, [CONTEXT-UPDATE] flags, browser recordings, screenshots, and test evidence for CI pipelines.
