PluginBench
Skill
Official
Review
Audit score 70

polyglot-test-agent

github/awesome-copilot

Multi-agent pipeline that generates comprehensive, compilable unit tests for any programming language.

What is polyglot-test-agent?

Generates workable unit tests across C#, TypeScript, JavaScript, Python, Go, Rust, Java, and more using a coordinated Research → Plan → Implement pipeline. Use when you need to create tests, improve coverage, or add test files that follow project conventions and actually compile and pass.

  • Analyzes codebase to detect language, testing framework, project structure, and build commands
  • Creates phased implementation plans that group files by complexity and dependencies
  • Generates test files that follow project patterns and conventions
  • Automatically builds and runs tests to verify they compile and pass
  • Fixes compilation and test failures using specialized fixer and linter agents
  • Supports happy path, edge case, and error case coverage strategies

How to install polyglot-test-agent

npx skills add https://github.com/github/awesome-copilot --skill polyglot-test-agent
Prerequisites
  • Project must have a build/test system configured
  • Testing framework should be installed or installable
  • VS Code with GitHub Copilot extension
Claude Code
Cursor
Windsurf
Cline

How to use polyglot-test-agent

  1. 1.Invoke the polyglot-test-generator agent with your test generation request and scope
  2. 2.The Research phase automatically analyzes your codebase (output: .testagent/research.md)
  3. 3.The Planning phase creates a phased implementation plan (output: .testagent/plan.md)
  4. 4.The Implementation phase executes each phase: reads source, writes tests, builds, tests, fixes, and lints
  5. 5.Review generated test files in .testagent/ folder and integrate into your project

Use cases

Good for
  • Generate unit tests for an entire project or specific files
  • Improve test coverage for existing codebases that lack tests
  • Create test files for new features or untested code modules
  • Add tests following project conventions without manual research
  • Generate tests in multiple languages within the same codebase
Who it's for
  • Developers improving test coverage on legacy or new projects
  • Teams standardizing test patterns across polyglot codebases
  • Engineers who want tests that compile and pass on first generation
  • QA engineers automating test creation for multiple languages

polyglot-test-agent FAQ

What programming languages are supported?

C#, TypeScript, JavaScript, Python, Go, Rust, Java, and more. The skill auto-detects the language and testing framework used in your project.

Will the generated tests actually compile and pass?

Yes. The pipeline includes build, test, fix, and lint phases that verify compilation and test execution before completion.

How does it handle project-specific conventions?

The Researcher phase analyzes existing tests and project structure to discover conventions. If none exist, it sources guidelines from unit-test-generation.prompt.md best practices.

What if tests fail or don't compile?

The polyglot-test-fixer agent automatically attempts to resolve compilation and test failures. Check .testagent/plan.md for expected test structure.

Can I specify a particular testing framework?

Yes. Include your framework preference in the initial request, e.g., 'Generate Jest tests for...' or 'Generate pytest tests for...'

Full instructions (SKILL.md)

Source of truth, from github/awesome-copilot.


name: polyglot-test-agent description: 'Generates comprehensive, workable unit tests for any programming language using a multi-agent pipeline. Use when asked to generate tests, write unit tests, improve test coverage, add test coverage, create test files, or test a codebase. Supports C#, TypeScript, JavaScript, Python, Go, Rust, Java, and more. Orchestrates research, planning, and implementation phases to produce tests that compile, pass, and follow project conventions.'

Polyglot Test Generation Skill

An AI-powered skill that generates comprehensive, workable unit tests for any programming language using a coordinated multi-agent pipeline.

When to Use This Skill

Use this skill when you need to:

  • Generate unit tests for an entire project or specific files
  • Improve test coverage for existing codebases
  • Create test files that follow project conventions
  • Write tests that actually compile and pass
  • Add tests for new features or untested code

How It Works

This skill coordinates multiple specialized agents in a Research → Plan → Implement pipeline:

Pipeline Overview

┌─────────────────────────────────────────────────────────────┐
│                     TEST GENERATOR                          │
│  Coordinates the full pipeline and manages state            │
└─────────────────────┬───────────────────────────────────────┘
                      │
        ┌─────────────┼─────────────┐
        ▼             ▼             ▼
┌───────────┐  ┌───────────┐  ┌───────────────┐
│ RESEARCHER│  │  PLANNER  │  │  IMPLEMENTER  │
│           │  │           │  │               │
│ Analyzes  │  │ Creates   │  │ Writes tests  │
│ codebase  │→ │ phased    │→ │ per phase     │
│           │  │ plan      │  │               │
└───────────┘  └───────────┘  └───────┬───────┘
                                      │
                    ┌─────────┬───────┼───────────┐
                    ▼         ▼       ▼           ▼
              ┌─────────┐ ┌───────┐ ┌───────┐ ┌───────┐
              │ BUILDER │ │TESTER │ │ FIXER │ │LINTER │
              │         │ │       │ │       │ │       │
              │ Compiles│ │ Runs  │ │ Fixes │ │Formats│
              │ code    │ │ tests │ │ errors│ │ code  │
              └─────────┘ └───────┘ └───────┘ └───────┘

Step-by-Step Instructions

Step 1: Determine the User Request

Make sure you understand what user is asking and for what scope. When the user does not express strong requirements for test style, coverage goals, or conventions, source the guidelines from unit-test-generation.prompt.md. This prompt provides best practices for discovering conventions, parameterization strategies, coverage goals (aim for 80%), and language-specific patterns.

Step 2: Invoke the Test Generator

Start by calling the polyglot-test-generator agent with your test generation request:

Generate unit tests for [path or description of what to test], following the [unit-test-generation.prompt.md](unit-test-generation.prompt.md) guidelines

The Test Generator will manage the entire pipeline automatically.

Step 3: Research Phase (Automatic)

The polyglot-test-researcher agent analyzes your codebase to understand:

  • Language & Framework: Detects C#, TypeScript, Python, Go, Rust, Java, etc.
  • Testing Framework: Identifies MSTest, xUnit, Jest, pytest, go test, etc.
  • Project Structure: Maps source files, existing tests, and dependencies
  • Build Commands: Discovers how to build and test the project

Output: .testagent/research.md

Step 4: Planning Phase (Automatic)

The polyglot-test-planner agent creates a structured implementation plan:

  • Groups files into logical phases (2-5 phases typical)
  • Prioritizes by complexity and dependencies
  • Specifies test cases for each file
  • Defines success criteria per phase

Output: .testagent/plan.md

Step 5: Implementation Phase (Automatic)

The polyglot-test-implementer agent executes each phase sequentially:

  1. Read source files to understand the API
  2. Write test files following project patterns
  3. Build using the polyglot-test-builder subagent to verify compilation
  4. Test using the polyglot-test-tester subagent to verify tests pass
  5. Fix using the polyglot-test-fixer subagent if errors occur
  6. Lint using the polyglot-test-linter subagent for code formatting

Each phase completes before the next begins, ensuring incremental progress.

Coverage Types

  • Happy path: Valid inputs produce expected outputs
  • Edge cases: Empty values, boundaries, special characters
  • Error cases: Invalid inputs, null handling, exceptions

State Management

All pipeline state is stored in .testagent/ folder:

FilePurpose
.testagent/research.mdCodebase analysis results
.testagent/plan.mdPhased implementation plan
.testagent/status.mdProgress tracking (optional)

Examples

Example 1: Full Project Testing

Generate unit tests for my Calculator project at C:\src\Calculator

Example 2: Specific File Testing

Generate unit tests for src/services/UserService.ts

Example 3: Targeted Coverage

Add tests for the authentication module with focus on edge cases

Agent Reference

AgentPurposeTools
polyglot-test-generatorCoordinates pipelinerunCommands, codebase, editFiles, search, runSubagent
polyglot-test-researcherAnalyzes codebaserunCommands, codebase, editFiles, search, fetch, runSubagent
polyglot-test-plannerCreates test plancodebase, editFiles, search, runSubagent
polyglot-test-implementerWrites test filesrunCommands, codebase, editFiles, search, runSubagent
polyglot-test-builderCompiles coderunCommands, codebase, search
polyglot-test-testerRuns testsrunCommands, codebase, search
polyglot-test-fixerFixes errorsrunCommands, codebase, editFiles, search
polyglot-test-linterFormats coderunCommands, codebase, search

Requirements

  • Project must have a build/test system configured
  • Testing framework should be installed (or installable)
  • VS Code with GitHub Copilot extension

Troubleshooting

Tests don't compile

The polyglot-test-fixer agent will attempt to resolve compilation errors. Check .testagent/plan.md for the expected test structure.

Tests fail

Review the test output and adjust test expectations. Some tests may require mocking dependencies.

Wrong testing framework detected

Specify your preferred framework in the initial request: "Generate Jest tests for..."