Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/boshi-xixixi/traeskill/csharp-mstestnpx skills add boshi-xixixi/TraeSkill --skill csharp-mstestgit clone --depth 1 https://github.com/boshi-xixixi/TraeSkillWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/boshi-xixixi/traeskill/csharp-mstest)<a href="https://agentmods.dev/skills/boshi-xixixi/traeskill/csharp-mstest"><img src="https://agentmods.dev/badge/skills/boshi-xixixi/traeskill/csharp-mstest.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00028 | $0.03283 |
| Opus 5 | $0.00014 | $0.01641 |
| Sonnet 5 | $0.00006 | $0.00657 |
| Haiku 4.5 | $0.00003 | $0.00328 |
Grade A, and why
csharp-mstest scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
Copies of this mod
2 near-identical copies found in the catalogue:
- csharp-mstest — 100% identical, 0 lines differ
- csharp-mstest — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 479 lines — stays where its author put it; the contents beside it link to each section on GitHub.
MSTest Best Practices (MSTest 3.x/4.x)
Your goal is to help me write effective unit tests with modern MSTest, using current APIs and best practices.
Project Setup
- Use a separate test project with naming convention
[ProjectName].Tests - Reference MSTest 3.x+ NuGet packages (includes analyzers)
- Consider using MSTest.Sdk for simplified project setup
- Run tests with
dotnet test
Test Class Structure
- Use
[TestClass]attribute for test classes - Seal test classes by default for performance and design clarity
- Use
[TestMethod]for test methods (prefer over[DataTestMethod]) - Follow Arrange-Act-Assert (AAA) pattern
- Name tests using pattern
MethodName_Scenario_ExpectedBehavior
[TestClass]
public sealed class CalculatorTests
{
[TestMethod]
public void Add_TwoPositiveNumbers_ReturnsSum()
{
// Arrange
var calculator = new Calculator();
// Act
var result = calculator.Add(2, 3);
// Assert
Assert.AreEqual(5, result);
}
}
Test Lifecycle
- Prefer constructors over
[TestInitialize]- enablesreadonlyfields and follows standard C# patterns - Use
[TestCleanup]for cleanup that must run even if test fails - Combine constructor with async
[TestInitialize]when async setup is needed
[TestClass]
public sealed class ServiceTests
{
private readonly MyService _service; // readonly enabled by constructor
public ServiceTests()
{
_service = new MyService();
}
[TestInitialize]
public async Task InitAsync()
{
// Use for async initialization only
await _service.WarmupAsync();
}
[TestCleanup]
public void Cleanup() => _service.Reset();
}
Execution Order
- Assembly Initialization -
[AssemblyInitialize](once per test assembly) - Class Initialization -
[ClassInitialize](once per test class) - Test Initialization (for every test method):
- Constructor
- Set
TestContextproperty [TestInitialize]
- Test Execution - test method runs
- Test Cleanup (for every test method):
[TestCleanup]DisposeAsync(if implemented)Dispose(if implemented)
- Class Cleanup -
[ClassCleanup](once per test class) - Assembly Cleanup -
[AssemblyCleanup](once per test assembly)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 479 lines · 28 tokens per session scan A 325e70e82f3e
csharp-mstest is a skill published in the GitHub repository boshi-xixixi/TraeSkill (261 stars, last pushed 3mo ago), licensed MIT. It adds 28 tokens to every session and 3,283 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
migrate-xunit-to-xunit-v3
Migrate .NET test projects from xUnit.net v2 to xunit.v3 and fix v3 breaks. Use for package/CPM conversion, OutputType=Exe, preserving the VSTest or MTP runner (including projects currently using YTest.MTP.XUnit2), incompatible TFMs, async void tests, string-to-Type attributes, custom Fact/Theory/BeforeAfterTest…
unity-csharp
写 Unity C# 时使用。生命周期、协程、GC、性能、序列化的实战规范。.
advanced-il-emit
Use IL emit for low-level code generation.
csharp-testing
C# and .NET testing patterns with xUnit, FluentAssertions, mocking, integration tests, and test organization best practices.
author-test
Generate a test given sample. Parameters: C# SDK repository root; Package name: one of Azure.AI.Projects, Azure.AI.Projects.Agents or Azure.AI.Extensions.OpenAI; the sample to use as a starting point for the test.
migrate-mstest-v3-to-v4
Use this skill before answering, planning, or editing any MSTest 3.x-to-4.x upgrade or post-upgrade failure. Triggers include "MSTest v4 breaking changes"; CS0507/CS0103/CS1061/CS1615; ExecuteAsync, CallerInfo, DisplayName, or custom TestMethodAttribute; ClassCleanupBehavior; ContainsKey; ThrowsExactly or…