ghc-test-generation

Teaches learners to validate AI-generated pytest tests and hand-write bug-revealing tests.

2|Updated Jun 1, 2026
One-click install
npx skills add https://github.com/jay-steenbergen/MSSAMentorAgent --skill ghc-test-generation-jay-steenbergen
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ghc-test-generation
Source: https://github.com/jay-steenbergen/MSSAMentorAgent/tree/main/.github/skills/tracks/github-copilot/ghc-test-generation
Command: npx skills add https://github.com/jay-steenbergen/MSSAMentorAgent --skill ghc-test-generation-jay-steenbergen

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pytest.

What problem does it solve? AI-generated tests often mirror the code's current behavior instead of its intended behavior, so they pass on buggy implementations and create false confidence. This Skill teaches learners to use GitHub Copilot's /tests command for the happy path while hand-writing the edge-case tests that actually reveal bugs. ## Core Features & Use Cases - Guided five-phase project: Build a buggy discount function, generate tests with /tests, request edge-case tests, then hand-write failing tests that expose input-validation bugs. - Reusable 4-step workflow: Docstring with examples, /tests for the happy path, steered edge-case prompts, and hand-written bug-revealing tests. - Use Case: A learner asks Copilot to generate pytest tests for a price-discount function, watches them all pass, then discovers the function silently increases prices for negative discount percentages and writes ValueError-raising tests to fix it. ## Quick Start Ask the mentor to start the ghc-test-generation project so I can learn how to verify Copilot-generated pytest tests and write my own bug-revealing tests.

Frequently Asked Questions about ghc-test-generation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate unit tests with GitHub Copilot?

Highlight a function and type /tests in Copilot Chat to generate a pytest or unittest file. The generated tests typically mirror the docstring examples and cover the happy path, so they should be treated as a starting point rather than complete coverage.

Why do Copilot-generated tests pass on buggy code?

Copilot infers assertions from the code's current behavior, not its intended behavior. If the implementation is wrong, the generated assertion encodes that wrong result, so the test passes while the bug remains.

How do I write a test that reveals a bug in Python?

Decide what inputs should be illegal, then write pytest tests asserting that behavior, such as expecting ValueError for negative discount percentages. Run pytest to confirm the test fails on the buggy implementation, then fix the function until it passes.

What are the limitations of AI-generated test suites?

AI-generated tests cannot decide what should be illegal or what would surprise a caller, because they derive expectations from existing code. Edge cases like negative inputs, values over 100 percent, and zero values usually require a human to define the intended contract.

What do I need before starting this Copilot testing project?

You need Python 3.10 or later with pytest installed, verified by running pytest --version. You should also have completed the ghc-chat-driven-debugging project so you are comfortable driving the Copilot Chat panel with /explain and /fix.