Use Copilot coding agent to write tests in dotnet/runtime
The .NET team used Copilot coding agent for ten months in dotnet/runtime; tests were a strength, though some broke on older frameworks or failed in CI.
Done withGitHub Copilot
- What they did
- Maintainers in dotnet/runtime assigned test-writing tasks to Copilot coding agent, including coverage additions. The agent used coverage tools and wrote tests. A maintainer reviewed each PR. The team added instructions covering testing conventions: no exact exception message assertions, conditional test attributes, and tests that can't run on .NET Framework. They also told it to avoid InternalsVisibleTo.
- How it went
- Testing PRs succeeded 75.6% of the time (99 PRs). The agent produced too many redundant tests, sometimes encoded buggy behavior as expected, and wrote tests that broke on older frameworks or in CI.
- Worth knowing
- Review needs pruning and care: 65.7% of the agent's added lines were tests, and local green runs didn't cover CI's many configurations.
Try it yourself with GitHub Copilot
In [owner/repo], write tests for [class or feature] following the existing test conventions and covering edge cases. Check that they run on every [framework or version] we support, not just the newest, and fix any CI failures. Open a draft PR listing which test cases you added and anything you could not get passing.
Want help getting this working? Join the Vibe Coding Academy ↗ Run by Alex Finn, who also runs this site.
Source: devblogs.microsoft.com · Undated
Related use cases
Run a solo company with eight agent departments
A founder set up CEO, CFO, COO, lawyer, accountant, marketing, CTO, and improver agents that share memory and consult each other.
Let Copilot Agent Mode handle coding, then constrain it
A developer let Copilot Agent Mode do all the coding, found they understood their code less, and moved to using it more narrowly.
Edit a large notebook with Copilot Agent Mode
The author asked Copilot Agent Mode for moderate changes and basic features in a large ipynb; it got halfway, stopped mid-line, and broke the notebook.
Build a C compiler with a team of parallel agents
Anthropic's engineering write-up on tasking Opus 4.6 agent teams with building a C compiler.
Ship more pull requests with Devin across tools
Ryan Carson uses Devin from iPhone, Slack, browser, GitHub and Linear for real work and reports higher PR shipping velocity.
Make GitHub profile and repos English-first
Codex inventoried the account, backed up content, and updated the profile, descriptions and README navigation across 87 public repos, then verified the changes against GitHub.
Submitted by SvenKunkka
Get 5 like this every morning
The best things people got an AI agent to do, each with the prompt to try it.