What problem does it solve?
Creates or updates PHPUnit 9 tests in the tests/ directory that conform to existing project patterns — TestCase subclass, declare(strict_types=1), namespace Detain\MyAdminMaxMind\Tests. Bootstrap stubs in tests/bootstrap.php and helpers in tests/helpers/ to safely mock MyAdmin globals during tests. Use when the user asks for adding tests, increasing coverage, or test-oriented improvements; not for production code changes, CI config, or non-test PHP files.
Core Features & Use Cases
- Generates PHPUnit TestCase classes with strict types and the correct namespace (Detain\MyAdminMaxMind\Tests) under tests/.
- Provides bootstrap stubs in tests/bootstrap.php and helpers in tests/helpers/ to safely mock MyAdmin globals during tests.
- Enforces test file naming (ending in Test.php) and alignment with project conventions for easy discovery and execution.
- Supports updating existing tests to reflect new or changed behavior, improving test coverage and reliability.
Quick Start
Prompt to generate a new PHPUnit test in tests/ that follows the project's conventions when you say add test or write tests.