1. Conduid
  2. RAG
  3. Dotnet Mtp Coverage MCP
MCP server · RAG

Dotnet Mtp Coverage MCP

MCP server for analyzing code coverage from MTP-based .NET test projects

Unclaimed rag
34Low

Scored 6 months ago · breakdown

About Dotnet Mtp Coverage MCP

Dotnet Mtp Coverage MCP is an MCP server published by glennawatson in the RAG category: mCP server for analyzing code coverage from MTP-based .NET test projects.

The repository has 3 stars and 1 forks, with the last commit a month ago. Recent commit activity is the strongest signal that reported issues will get attention.

Install

From source
git clone https://github.com/glennawatson/dotnet-mtp-coverage-mcp

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Tools (6)

GetClassCoverageGets overall coverage summary for a specific class

Parameters not published.

GetMethodCoverageGets overall coverage summary for a specific method

Parameters not published.

GetMissedCoverageForFileGets missed lines and branches for a specific source file

Parameters not published.

GetProjectCoverageGets overall coverage summary for a specific project/package

Parameters not published.

GetSolutionCoverageGets overall coverage summary for an entire solution

Parameters not published.

GetSolutionMissedCoverageGets a detailed report of ALL missed lines and branches across a solution

Parameters not published.

Ask AI

✦

Ask AI about Dotnet Mtp Coverage MCP

Powered by Claude · Grounded in docs

I know everything about Dotnet Mtp Coverage MCP. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

  • ✓README presentThe repository ships documentation.

5 checks have not been run yet.

README

UnitTestMcp

An MCP (Model Context Protocol) server for analyzing code coverage from MTP (Microsoft Testing Platform) based .NET test projects. Parses Cobertura XML coverage reports and exposes coverage data through MCP tools for AI-assisted development workflows.

Features

  • Parse Cobertura XML coverage reports (the standard output from dotnet test with code coverage)
  • Query missed lines and branches for individual source files
  • Get overall coverage for classes, methods, projects, and entire solutions
  • Generate comprehensive missed coverage reports across a solution
  • Discover and merge multiple coverage reports automatically

Prerequisites

  • .NET 10 SDK or later
  • An MTP-compatible test framework (e.g., TUnit, MSTest, xUnit v3)
  • Code coverage collection configured (via testconfig.json or CLI flags)

Installation

Quick Install

Click to install in your preferred environment:

VS Code - Install MTP Coverage MCP VS Code Insiders - Install MTP Coverage MCP Visual Studio - Install MTP Coverage MCP

Note:

  • These install links are prepared for the intended NuGet package V1.* identity UnitTestMcp.Server and do not require the dotnet tool to be installed first.
  • If you are not able to use these links yet, use one of the manual configuration options below.
{
  "servers": {
    "MTP.UnitTest.MCP": {
      "type": "stdio",
      "command": "dnx",
      "args": [
        "UnitTestMcp.Server@1.*",
        "--yes"
      ]
    }
  }
}

To install as a dotnet tool:

dotnet tool install --global UnitTestMcp.Server

Or run directly from source:

cd src
dotnet run --project UnitTestMcp.Server

MCP Tools

Tool Description
GetMissedCoverageForFile Gets missed lines and branches for a specific source file
GetClassCoverage Gets overall coverage summary for a specific class
GetMethodCoverage Gets overall coverage summary for a specific method
GetProjectCoverage Gets overall coverage summary for a specific project/package
GetSolutionCoverage Gets overall coverage summary for an entire solution
GetSolutionMissedCoverage Gets a detailed report of ALL missed lines and branches across a solution

Usage

Generating Coverage Reports

With MTP, code coverage is configured via testconfig.json and the Microsoft.Testing.Extensions.CodeCoverage extension. Add the extension to your test project and configure it for Cobertura output:

{
    "extensions": [
        {
            "extensionId": "Microsoft.Testing.Extensions.CodeCoverage",
            "settings": {
                "format": "cobertura"
            }
        }
    ]
}

Then run your tests normally:

dotnet test

Configuring as an MCP Server

The following examples are for end users consuming the published global tool. You do not need to build the project from source to use these configurations.

Claude Code CLI

Add the installed tool as a stdio MCP server with:

claude mcp add dotnet-mtp-coverage-mcp -- dotnet-mtp-coverage-mcp

If your local setup needs environment variables, Claude Code also supports:

claude mcp add -e SOME_SETTING=value dotnet-mtp-coverage-mcp -- dotnet-mtp-coverage-mcp

No additional subprocess flags or arguments are required when using the installed global tool.

JSON Configuration

For JSON-based MCP clients (for example, Claude Desktop or other clients that use an mcpServers object), use one of the following stdio server configurations.

Installed .NET tool:

{
  "mcpServers": {
    "dotnet-mtp-coverage-mcp": {
      "command": "dotnet-mtp-coverage-mcp"
    }
  }
}

With environment variables:

{
  "mcpServers": {
    "dotnet-mtp-coverage-mcp": {
      "command": "dotnet-mtp-coverage-mcp",
      "env": {
        "SOME_SETTING": "value"
      }
    }
  }
}

Cobertura XML Format

This tool expects Cobertura XML format, which is the standard output from the Microsoft.Testing.Extensions.CodeCoverage extension when configured with "format": "cobertura" in testconfig.json.

Building

cd src
dotnet build

Running Tests

cd src
dotnet test

Project Structure

src/
  UnitTestMcp.Core/         # Core library: models, parsers, services
    Models/                  # Coverage data models (records)
    Parsers/                 # Cobertura XML parser
    Services/                # Coverage query service
  UnitTestMcp.Server/        # MCP server executable
    Tools/                   # MCP tool definitions
  tests/
    UnitTestMcp.Tests/       # TUnit tests
      TestData/              # Sample Cobertura XML fixtures

Attribution

The Cobertura XML parsing logic and coverage data model concepts in this project are adapted from ReportGenerator by Daniel Palme, licensed under the Apache License 2.0. ReportGenerator is a comprehensive code coverage report generation tool that supports many input and output formats.

License

MIT License - Copyright (c) 2026 Glenn Watson. See LICENSE for details.

README copy captured when this server was indexed; it may lag the repository. The original is authoritative.

Questions

About Dotnet Mtp Coverage MCP

How do I install Dotnet Mtp Coverage MCP?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is Dotnet Mtp Coverage MCP safe to use with an AI agent?

Its trust score is 34 out of 100 (low). It passes 1 of the 1 static security checks run so far. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Dotnet Mtp Coverage MCP still maintained?

Yes — the last commit was a month ago. The repository has 3 stars and 1 forks.