Skip to content

Recovered: feat(agent): add Gemini CLI install target (#57 by @merlinsantiago982-cmd)#247

Open
jangjos-128 wants to merge 4 commits into
TestSprite:mainfrom
merlinsantiago982-cmd:feat/gemini-agent-target
Open

Recovered: feat(agent): add Gemini CLI install target (#57 by @merlinsantiago982-cmd)#247
jangjos-128 wants to merge 4 commits into
TestSprite:mainfrom
merlinsantiago982-cmd:feat/gemini-agent-target

Conversation

@jangjos-128

@jangjos-128 jangjos-128 commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add a gemini agent target that installs TestSprite guidance into GEMINI.md
  • generalize managed-section metadata so Codex and Gemini can each preserve user-authored root instruction files
  • update agent docs, help snapshots, and install/list coverage

Safety

  • GEMINI.md uses sentinel-delimited managed-section writes, so existing project instructions outside the TestSprite block are preserved
  • re-running install replaces only the TestSprite section

Tests

  • npm run format:check
  • npm run test -- src/lib/agent-targets.test.ts src/commands/agent.test.ts test/help.snapshot.test.ts
  • npm run typecheck
  • npm run lint
  • npm run build

Summary by CodeRabbit

  • New Features
    • Added Gemini as a supported agent target with managed-section installation.
    • Added the testsprite-onboard skill for creating an initial test suite.
    • Agent installation now supports selecting specific skills with --skill.
    • Setup and installation results now show installed skills.
  • Documentation
    • Expanded setup guidance for interactive and CI workflows.
    • Clarified Python requirements and execution behavior for generated and replaced backend tests.
    • Documented managed-section behavior for Codex and Gemini, including rerun handling.

@coderabbitai

coderabbitai Bot commented Jul 13, 2026

Copy link
Copy Markdown

Review Change Stack

Walkthrough

The PR introduces a registry for multiple agent skills, adds onboarding content, supports Gemini managed sections, updates installation and initialization reporting, refines managed-section detection, and expands CLI documentation and unit/e2e coverage.

Changes

Agent skills and installation

Layer / File(s) Summary
Skill registry and target rendering
src/lib/agent-targets.ts, src/lib/agent-targets.test.ts
Adds testsprite-onboard, Gemini target metadata, per-skill paths and rendering, and Codex aggregation helpers.
Onboarding skill content
docs/cli-v1-agent-install/onboard-skill-template.md, skills/testsprite-onboard.skill.md
Defines onboarding, project creation, test authoring, smoke runs, reporting, quality checks, and verification handoff.
Skill-aware install and list flow
src/commands/agent.ts, src/commands/agent.test.ts
Adds --skill, multi-skill install results, managed-section composition and budgets, Gemini installation, and skill-aware listing.
Setup and initialization reporting
src/commands/init.ts
Aggregates multiple install results and reports installed skills in initialization summaries.
Managed-section detection
src/lib/skill-nudge.ts, src/lib/skill-nudge.test.ts
Uses target-specific sentinels to detect installed managed sections, including Gemini.
Backend verification guidance
skills/testsprite-verify.codex.md, skills/testsprite-verify.skill.md
Documents explicit Python test invocation, sandbox dependencies, and HTTP-based backend validation.
CLI documentation and end-to-end coverage
DOCUMENTATION.md, README.md, test/e2e/*
Documents Gemini, Python code commands, and CI setup while expanding multi-skill, listing, setup, and target-matrix coverage.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related issues

Possibly related PRs

Suggested reviewers: ruili-testsprite, zeshi-du

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding a Gemini CLI install target.
Docstring Coverage ✅ Passed Docstring coverage is 90.91% which is sufficient. The required threshold is 80.00%.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
⚔️ Resolve merge conflicts
  • Resolve merge conflict in branch feat/gemini-agent-target

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed: private package registry requires authentication. Disable ESLint in CodeRabbit settings or use public packages.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Around line 64-70: Update the README quickstart text around testsprite setup
to describe installing both the verification and onboarding skills, replacing
the singular references in the setup description and agent guidance while
preserving the existing command examples and links.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: ffbc3408-8c31-4ef5-b60d-53ad397f9cb7

📥 Commits

Reviewing files that changed from the base of the PR and between 60d55e4 and fcc3929.

⛔ Files ignored due to path filters (1)
  • test/__snapshots__/help.snapshot.test.ts.snap is excluded by !**/*.snap, !**/*.snap
📒 Files selected for processing (15)
  • DOCUMENTATION.md
  • README.md
  • docs/cli-v1-agent-install/onboard-skill-template.md
  • skills/testsprite-onboard.skill.md
  • skills/testsprite-verify.codex.md
  • skills/testsprite-verify.skill.md
  • src/commands/agent.test.ts
  • src/commands/agent.ts
  • src/commands/init.ts
  • src/lib/agent-targets.test.ts
  • src/lib/agent-targets.ts
  • src/lib/skill-nudge.test.ts
  • src/lib/skill-nudge.ts
  • test/e2e/agent-install.e2e.test.ts
  • test/e2e/setup.e2e.test.ts

Comment thread README.md
Comment on lines +64 to +70
`testsprite setup` prompts for your [API key](https://www.testsprite.com), verifies it, and installs the verification-loop skill for your coding agent (`claude`, `cursor`, `cline`, `antigravity`, `codex`, `gemini`, etc.) — one command, so your agent is wired to verify its own work. Non-interactive (CI / onboarding scripts):

```bash
TESTSPRITE_API_KEY=sk-... testsprite setup --from-env --yes --agent claude
```

> **Pointing a coding agent (Claude Code, Cursor, Codex, Cline, …) at TestSprite?** Have it run `testsprite setup` first — that installs the verification skill, so the agent knows how to create, run, and triage tests on its own (instead of guessing from this README). New here? Start with the **[getting-started overview](https://docs.testsprite.com/cli/getting-started/overview)**.
> **Pointing a coding agent (Claude Code, Gemini CLI, Cursor, Codex, Cline, …) at TestSprite?** Have it run `testsprite setup` first — that installs the verification skill, so the agent knows how to create, run, and triage tests on its own (instead of guessing from this README). New here? Start with the **[getting-started overview](https://docs.testsprite.com/cli/getting-started/overview)**.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Quickstart understates what setup now installs.

testsprite setup now installs the full DEFAULT_SKILLS set (testsprite-verify and testsprite-onboard), consistent with init.ts's pluralized SETUP_DESCRIPTION. Lines 64 and 70 still describe only "the verification-loop skill" / "the verification skill" (singular), omitting the onboarding skill. Consider pluralizing to mention both the verification and onboarding skills so the docs match behavior.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 64 - 70, Update the README quickstart text around
testsprite setup to describe installing both the verification and onboarding
skills, replacing the singular references in the setup description and agent
guidance while preserving the existing command examples and links.

@jangjos-128

Copy link
Copy Markdown
Contributor Author

Hi @merlinsantiago982-cmd 👋 — this is the recovery of your PR #57 , which was auto-closed by an error in our 2026-07-09 release process. Your commits are intact — thank you for the contribution!

It currently shows merge conflicts because main has moved on since your branch was cut. To clear them, update your PR branch (BRANCH) against the latest main — either option works and both update this PR in place:

Option A — merge (no force-push):

git checkout BRANCH
git fetch upstream          # your remote for TestSprite/testsprite-cli (may be "origin")
git merge upstream/main     # resolve conflicts, commit
git push

Option B — rebase (cleaner history, needs force):

git checkout BRANCH
git fetch upstream
git rebase upstream/main    # resolve conflicts
git push --force-with-lease

Once you push, the conflicts here resolve automatically and we'll take it into review.

Sorry again for the extra step!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants