testing

Create and run pytest and Playwright test suites for TheMoon.

Updated Nov 22, 2025
One-click install
npx skills add https://github.com/usermaum/Themoon --skill testing-usermaum
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: testing
Source: https://github.com/usermaum/Themoon/tree/main/.claude/plugins/mas-agents/skills/testing
Command: npx skills add https://github.com/usermaum/Themoon --skill testing-usermaum

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the complexity of setting up, running, and managing tests for the TheMoon project, ensuring code quality and reliability.

Core Features & Use Cases

  • Test Suite Management: Provides guidance on structuring and running backend (pytest) and frontend/E2E (Playwright) tests.
  • Fixture and Pattern Examples: Offers practical examples for database sessions, FastAPI test clients, and sample data setup.
  • Use Case: When a new feature is developed, use this Skill to generate comprehensive unit and integration tests, ensuring it functions as expected and doesn't introduce regressions.

Quick Start

Use the testing skill to run all backend unit tests for the application.

Frequently Asked Questions about testing

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

FAQPage Schema
How do I structure pytest fixtures for FastAPI test clients and database sessions?

Use pytest fixtures to manage FastAPI test clients and database sessions. The testing Skill provides practical patterns for setting up sample data and database sessions, ensuring backend tests run efficiently and reliably without manual setup overhead.

What's the best way to run E2E tests with Playwright for a FastAPI backend?

Run E2E tests with Playwright by leveraging clear execution commands provided by the testing Skill. It structures frontend and backend tests together, ensuring comprehensive coverage across the full application stack without isolated configurations.

How does code coverage tracking work with pytest and Playwright test suites?

Code coverage tracking works by executing pytest and Playwright test suites against defined goals. The testing Skill ensures adherence to coverage targets for robust software engineering, validating that new features function correctly and prevent regressions.

Can I generate sample data automatically for integration tests?

Yes, you can generate sample data for integration tests. The testing Skill supports efficient test development through fixture patterns and sample data generation, allowing you to set up FastAPI test clients and database sessions with consistent mock inputs.

When should I use pytest versus Playwright for my testing workflows?

Use pytest for backend unit and integration tests, and Playwright for frontend E2E tests. The testing Skill manages both methodologies, providing specific fixture examples and execution commands to streamline comprehensive test suite development.