·pytest-coder
</>

pytest-coder

使用固定装置、参数化、模拟、异步测试和现代模式编写 pytest 测试。创建或更新 Python 测试文件时使用。不适用于单元测试 - 请使用标准库模式。

23安装·1热度·@majesticlabs-dev

安装

$npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill pytest-coder

如何安装 pytest-coder

通过命令行快速安装 pytest-coder AI 技能到你的开发环境

  1. 打开终端: 打开你的终端或命令行工具(如 Terminal、iTerm、Windows Terminal 等)
  2. 运行安装命令: 复制并运行以下命令:npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill pytest-coder
  3. 验证安装: 安装完成后,技能将自动配置到你的 AI 编程环境中,可以在 Claude Code、Cursor 或 OpenClaw 中使用

来源:majesticlabs-dev/majestic-marketplace。

SKILL.md

查看原文

| AAA Pattern | Arrange-Act-Assert for every test | | Behavior over Implementation | Test what code does, not how | | Isolation | Tests must be independent | | Fast Tests | Mock I/O, minimize database hits | | Descriptive Names | Test name explains the scenario | | Coverage | Test happy paths AND edge cases |

| function | Per test (default) | Most fixtures | | class | Per test class | Shared setup within class | | module | Per module | Expensive setup shared by module | | session | Entire test run | Database connections, servers |

| Tests depend on order | Flaky, hard to debug | Use fixtures, isolate | | Testing implementation | Brittle tests | Test behavior | | Too many assertions | Hard to identify failure | One assertion per test | | No error case tests | Missing coverage | Test exceptions explicitly | | Slow unit tests | Slow feedback | Mock I/O, use in-memory DB |

可引用信息

为搜索与 AI 引用准备的稳定字段与命令。

安装命令
npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill pytest-coder
分类
</>开发工具
认证
收录时间
2026-02-23
更新时间
2026-03-10

Browse more skills from majesticlabs-dev/majestic-marketplace

快速解答

什么是 pytest-coder?

使用固定装置、参数化、模拟、异步测试和现代模式编写 pytest 测试。创建或更新 Python 测试文件时使用。不适用于单元测试 - 请使用标准库模式。 来源:majesticlabs-dev/majestic-marketplace。

如何安装 pytest-coder?

打开你的终端或命令行工具(如 Terminal、iTerm、Windows Terminal 等) 复制并运行以下命令:npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill pytest-coder 安装完成后,技能将自动配置到你的 AI 编程环境中,可以在 Claude Code、Cursor 或 OpenClaw 中使用

这个 Skill 的源码在哪?

https://github.com/majesticlabs-dev/majestic-marketplace