Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
makfly avatar

Symfony:api Platform Tests Skill

  • 418 installs
  • 190 repo stars
  • Updated August 6, 2026
  • makfly/superpowers-symfony

symfony:api-platform-tests is an agent skill that writes PHPUnit and API Platform functional tests verifying endpoints, serialization, filters, security, and regression behavior before Symfony API release.

About

symfony:api-platform-tests is an agent skill in makfly/superpowers-symfony for testing API Platform resources with ApiPlatform\Symfony\Bundle\Test\ApiTestCase. It defines operation-level contracts, implements resources and DTO mappings, and validates collections, items, filters, pagination, authentication, and JSON schema assertions using Zenstruck Foundry v2 factories and DAMADoctrineTestBundle rollbacks. The reference guide covers create, update, patch, delete, search, range, and order filters plus denormalization error cases on API Platform v3 through v4. Developers invoke it when evolving API contracts and need happy-path and negative-path functional coverage that stays aligned with serialization and security policies.

  • Bootstrap API test clients with KernelTestCase
  • Assert JSON-LD, JSON, and OpenAPI contracts
  • Cover filters, pagination, and custom operations
  • Test authenticated and forbidden request paths
  • Stabilize fixtures and database isolation

Symfony:Api Platform Tests by the numbers

  • 418 all-time installs (skills.sh)
  • Ranked #649 of 2,189 Testing & QA skills by installs in the Skillselion catalog
  • Data as of Aug 11, 2026 (Skillselion catalog sync)
npx skills add https://github.com/makfly/superpowers-symfony --skill symfonyapi-platform-tests

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs418
repo stars190
Last updatedAugust 6, 2026
Repositorymakfly/superpowers-symfony

How do you test API Platform endpoints in Symfony?

Write PHPUnit and API Platform functional tests that verify endpoints, serialization, filters, security, and regression behavior before release.

Who is it for?

Symfony backend engineers shipping API Platform v3–v4 APIs who need ApiTestCase functional tests with Foundry data and schema checks.

Skip if: Non-Symfony REST projects, frontend-only testing, or teams not using API Platform's ApiTestCase client.

When should I use this skill?

A developer asks to test API Platform resources, assert hydra collections, verify filters, or cover authentication and validation failures in Symfony APIs.

What you get

PHPUnit ApiTestCase suites, Foundry-backed fixtures, schema assertions, and verified happy and negative API contract results.

  • PHPUnit ApiTestCase functional test classes
  • Foundry factory-backed API fixtures
  • Documented contract and security verification results

By the numbers

  • Parent superpowers-symfony repository bundles 44 skill definitions
  • Reference guide lists 6 API Platform testing best practices
  • Documents ApiTestCase patterns for API Platform v3 through v4

Files

SKILL.mdMarkdownGitHub ↗

Api Platform Tests (Symfony)

Use when

  • Designing or evolving API Platform contracts and operations.
  • Aligning serialization, validation, and security behavior.

Default workflow

1. Define operation-level contract and payload boundaries. 2. Implement resource/DTO/provider/processor changes with explicit mapping. 3. Apply operation-specific validation and security constraints. 4. Validate functional behavior across happy and negative paths.

Guardrails

  • Keep API contract explicit and version-aware.
  • Avoid exposing internal entity fields implicitly.
  • Prevent drift between docs and actual serialization.

Progressive disclosure

  • Use this file for execution posture and risk controls.
  • Open references when deep implementation details are needed.

Output contract

  • API artifacts changed (resource/DTO/provider/processor).
  • Contract/security decisions and rationale.
  • Functional verification results.

References

  • reference.md
  • docs/complexity-tiers.md

Related skills

How it compares

Pick symfony:api-platform-tests over generic PHPUnit skills when you need API Platform hydra assertions, Foundry fixtures, and contract-level schema checks.

FAQ

Which test base class does symfony:api-platform-tests use?

symfony:api-platform-tests uses ApiPlatform\Symfony\Bundle\Test\ApiTestCase, stable from API Platform v3 through v4. Tests call static::createClient()->request() and assert hydra collections, items, status codes, and JSON schemas.

How does symfony:api-platform-tests reset test data?

symfony:api-platform-tests recommends Zenstruck Foundry v2 factories with the #[ResetDatabase] attribute or ResetDatabase trait plus DAMADoctrineTestBundle transactional rollbacks between PHPUnit tests to keep database state isolated.

What API behaviors should symfony:api-platform-tests cover?

symfony:api-platform-tests covers success and failure paths including validation 422 responses, authentication 401 cases, authorization 403 checks, not-found 404s, search and range filters, pagination, and assertMatchesResourceCollectionJsonSchema structure checks.

Testing & QAbackendtesting

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.