MCP HubMCP Hub
返回技能列表

Analyzing Test Coverage

jeremylongshore
更新于 Today
80 次查看
1,053
135
1,053
在 GitHub 上查看
testing

关于

This skill analyzes code coverage metrics to identify untested code and generate comprehensive coverage reports. It helps developers improve code quality by pinpointing test gaps and ensuring adequate test coverage. Use trigger terms like "analyze coverage," "code coverage report," or "cov" when you need to assess or enhance your test suite.

快速安装

Claude Code

推荐
插件命令推荐
/plugin add https://github.com/jeremylongshore/claude-code-plugins-plus-skills
Git 克隆备选方式
git clone https://github.com/jeremylongshore/claude-code-plugins-plus-skills.git ~/.claude/skills/Analyzing Test Coverage

在 Claude Code 中复制并粘贴此命令以安装该技能

技能文档

Overview

This skill enables Claude to analyze code coverage metrics, pinpoint areas of untested code, and generate detailed reports. It helps you identify gaps in your test suite and ensure comprehensive code coverage.

How It Works

  1. Coverage Data Collection: Claude executes the project's test suite with coverage tracking enabled (e.g., using nyc, coverage.py, or JaCoCo).
  2. Report Generation: The plugin parses the coverage data and generates a detailed report, including metrics for line, branch, function, and statement coverage.
  3. Uncovered Code Identification: Claude highlights specific lines or blocks of code that are not covered by any tests.

When to Use This Skill

This skill activates when you need to:

  • Analyze the overall code coverage of your project.
  • Identify specific areas of code that lack test coverage.
  • Generate a detailed report of code coverage metrics.
  • Enforce minimum code coverage thresholds.

Examples

Example 1: Analyzing Project Coverage

User request: "Analyze code coverage for the entire project"

The skill will:

  1. Execute the project's test suite with coverage tracking.
  2. Generate a comprehensive coverage report, showing line, branch, and function coverage.

Example 2: Identifying Untested Code

User request: "Show me the untested code in the src/utils.js file"

The skill will:

  1. Analyze the coverage data for src/utils.js.
  2. Highlight the lines of code in src/utils.js that are not covered by any tests.

Best Practices

  • Configuration: Ensure your project has a properly configured coverage tool (e.g., nyc in package.json).
  • Thresholds: Define minimum coverage thresholds to enforce code quality standards.
  • Report Review: Regularly review coverage reports to identify and address coverage gaps.

Integration

This skill can be integrated with other testing and CI/CD tools to automate coverage analysis and reporting. For example, it can be used in conjunction with a linting plugin to identify both code style issues and coverage gaps.

GitHub 仓库

jeremylongshore/claude-code-plugins-plus-skills
路径: backups/plugin-enhancements/plugin-backups/test-coverage-analyzer_20251020_005115/skills/skill-adapter
aiautomationclaude-codedevopsmarketplacemcp

相关推荐技能

content-collections

Content Collections 是一个 TypeScript 优先的构建工具,可将本地 Markdown/MDX 文件转换为类型安全的数据集合。它专为构建博客、文档站和内容密集型 Vite+React 应用而设计,提供基于 Zod 的自动模式验证。该工具涵盖从 Vite 插件配置、MDX 编译到生产环境部署的完整工作流。

查看技能

evaluating-llms-harness

测试

该Skill通过60+个学术基准测试(如MMLU、GSM8K等)评估大语言模型质量,适用于模型对比、学术研究及训练进度追踪。它支持HuggingFace、vLLM和API接口,被EleutherAI等行业领先机构广泛采用。开发者可通过简单命令行快速对模型进行多任务批量评估。

查看技能

cloudflare-turnstile

这个Skill提供完整的Cloudflare Turnstile集成知识,用于在表单、登录页面和API端点中实现无验证码的机器人防护。它支持React/Next.js/Hono等框架集成,涵盖令牌验证、错误代码调试和端到端测试等场景。通过运行后台不可见挑战,在保持用户体验的同时有效阻止自动化流量和垃圾信息。

查看技能

webapp-testing

测试

该Skill为开发者提供了基于Playwright的本地Web应用测试工具集,支持自动化测试前端功能、调试UI行为、捕获屏幕截图和查看浏览器日志。它包含管理服务器生命周期的辅助脚本,可直接作为黑盒工具运行而无需阅读源码。适用于需要快速验证本地Web应用界面和交互功能的开发场景。

查看技能