Write PHPUnit tests for a WordPress plugin or theme.
“글쓰기, 콘텐츠, 문서” 분야의 스킬이에요. Claude Code, Codex, OpenCode 외 32개 에이전트용 명령이 준비돼 있어요.
전체 설명
Write PHPUnit tests for a WordPress plugin or theme. Covers the integration base class `WP_UnitTestCase` and its snake_case `set_up()` / `tear_down()` fixtures (and why WordPress uses them via phpunit-polyfills), the per-test DB transaction rollback, the factory system (`self::factory()->post->create()`, `create_many()`, `create_and_get()`, `wpSetUpBeforeClass()`), WP assertions (`assertWPError`, `assertEqualSets`), HTTP mocking with the `pre_http_request` filter, data providers and `@group`, and the crucial distinction that `WP_UnitTestCase` is an INTEGRATION test (real WP + DB) while true unit tests need Brain Monkey or WP_Mock to mock WP functions. Use when authoring or reviewing tests, choosing unit vs integration, mocking HTTP/WP functions, or fixing fixture/factory mistakes. For scaffolding and CI see wp-phpunit-test-setup.
Skill
글쓰기, 콘텐츠, 문서
에이전트 35개
26 스타
MIT
이 항목의 출처는 Skills-2M 오픈 데이터셋이에요. ANG은 이 스킬을 실행하거나 감사하지 않았어요. 설치하기 전에 소스를 확인하세요.