Unit tester

From I-Synergy/I-Synergy.Framework · View interactive version

Unit tester is an AI agent skill from the GitHub repository I-Synergy/I-Synergy.Framework. MSTest unit testing specialist. Use when writing unit tests, creating test classes, implementing BDD scenarios with Reqnroll, or ensuring test coverage for handlers and components.

How to use this skill

Skill file

Unit Tester Skill

Specialized agent for MSTest, Moq, and Reqnroll testing.

Expertise Areas

Responsibilities

  1. Create Unit Tests
  1. Write BDD Scenarios
  1. Mock Dependencies
  1. Ensure Coverage

Test Frameworks (REQUIRED)

Test Naming Convention

MethodName_Scenario_ExpectedResult

Examples:
HandleAsync_ValidCommand_Creates{Entity}Successfully
HandleAsync_NullCommand_ThrowsArgumentNullException
HandleAsync_NegativeAmount_ThrowsArgumentException

Test Structure (AAA Pattern)

[TestMethod]
public async Task MethodName_Scenario_ExpectedResult()
{
    // Arrange
    var command = new Create{Entity}Command(...);

    // Act
    var result = await _handler.HandleAsync(command);

    // Assert
    Assert.IsNotNull(result);
    _mockContext.Verify(x => x.Method(...), Times.Once);
}

Gherkin Scenario Template

Feature: {Entity} Management
  As a user
  I want to manage {entities}
  So that I can achieve a business goal

  Scenario: Description of scenario
    Given precondition
    When action
    Then expected result
    And additional assertion

Templates to Use

Patterns to Follow

Test Documentation

The test artifacts this skill produces are mapped to ISO/IEC/IEEE 29119-3, right-sized, in

.ai/reference/test-documentation.md. Three consequences:

docs/slices/{Domain}/{Entity}.{Operation}/blueprint.json to

docs/slices/{Domain}/{Entity}.{Operation}/test-plan.md, using

.ai/reference/templates/test-plan.md.txt. Its entry and exit criteria are what the traceability

validator's checks T5/T6 measure against, so keep them concrete.

.ai/reference/traceability.md is that document. A second, hand-written copy is the one that

goes stale.

.ai/reference/templates/test-incident-report.md.txt. A failure fixed in the same edit needs no

report. The completion report (Clause 7.4) is written per release, not per slice, and this skill's

run results feed it.

Checklist Before Completion

(docs/slices/{Domain}/{Entity}.{Operation}/test-plan.md)

referenced from a test — validate-traceability.py reports no unresolved reference and no

T5/T6 warning for it

expected vs actual results, a severity from .ai/reference/quality-model.md, and a status

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.