generating-tests

Generate xUnit tests for C#/.NET ABP Framework code from source files.

Updated Jan 23, 2026
One-click install
npx skills add https://github.com/alexsandrocruz/DominusLeads --skill generating-tests-alexsandrocruz
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: generating-tests
Source: https://github.com/alexsandrocruz/DominusLeads/tree/main/backend/Sapienza.Leads/.claude/skills/generate-tests
Command: npx skills add https://github.com/alexsandrocruz/DominusLeads --skill generating-tests-alexsandrocruz

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill automates the creation of robust xUnit tests for C#/.NET ABP Framework projects by analyzing source code and generating test scaffolds for AppServices, Validators, and HTTP API Controllers.

Core Features & Use Cases

  • Automated Test Scaffolding: Generates unit tests for application services, validators, and integration tests for HTTP APIs, reducing manual boilerplate.
  • Test Coverage Guidance: Produces starter tests that cover common scenarios like valid inputs, not-found cases, and authorization checks.
  • Language/Framework Alignment: Produces tests compatible with xUnit, Shouldly, and NSubstitute conventions used in ABP-based projects.

Quick Start

Use the generator to produce tests from a source file: python scripts/generate_tests.py src/MyAppService.cs --type unit

Frequently Asked Questions about generating-tests

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

FAQPage Schema
How do I generate xUnit tests for ABP Framework AppService classes?

You generate xUnit tests for ABP AppService classes by running a Python script that parses C# source files and emits unit test scaffolds covering public methods, constructor dependencies, and authorization checks.

What is the best way to automate unit testing for C# ABP validators?

Automating unit testing for C# ABP validators involves using a Python-based generator that analyzes source code and emits xUnit test scaffolds covering validation rules and valid input scenarios.

Can I generate integration tests for ABP HTTP API Controllers automatically?

Yes, you can automatically generate integration tests for ABP HTTP API Controllers by running a source code analyzer that emits xUnit scaffolds targeting not-found cases and API endpoint behaviors.

Does the generated ABP test scaffolding work with NSubstitute and Shouldly?

Yes, the generated ABP test scaffolding aligns directly with NSubstitute and Shouldly conventions, producing tests compatible with standard C#/.NET ABP project test structures.

How do I run the Python script to scaffold tests from a C# source file?

You run the Python script via command line by passing the source file path and test type, such as `python scripts/generate_tests.py src/MyAppService.cs --type unit`, to output tests under the ABP project test structure.

What scenarios do the generated xUnit tests cover for ABP applications?

The generated xUnit tests cover common ABP scenarios including valid inputs, not-found cases, authorization checks, constructor dependencies, and validation rules for AppServices, Validators, and HTTP API Controllers.