Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Openapi Contract Testing Laravel Package

studio-design/openapi-contract-testing

Validate Laravel/PHP API responses and requests against your OpenAPI spec with contract tests that catch breaking changes early. Supports schema validation, status codes, and CI-friendly assertions.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit: Gesso is a test-time contract/spec validation toolkit, not a runtime dependency. That makes it a good fit for Laravel/PHP teams that want stronger API contract checks without changing production architecture. v2.7.0 improves fit by sharing configuration between PHPUnit and Laravel, reading route-side parity exclusions and spec lists from config, defaulting Symfony/PSR-7 policy hooks from shared config, and standardising CLI output across subcommands.

Integration feasibility: High. The package appears Composer-installable and CI-oriented, with doctor, coverage:merge, coverage:gate, contract checks, and now --emit-config to generate an equivalent gesso.php. The new global --format and --output-file flags make it easier to wire into existing CI/reporting pipelines. The new spec-driven HTTP client fakes for consumer-side contract testing reduce dependence on live provider services and improve CI determinism.

Technical risk: No declared hard breaking changes in v2.7.0, but there is migration risk. Named contract checks move to the Contract namespace behind a deprecated Fuzz alias, so teams should plan namespace cleanup before the alias is removed. Config normalisation changes and shared PHPUnit/Laravel config increase coupling between test frameworks and package config. Validation changes around form encoding, explode, part headers, body boundaries, and JSON object decoding can alter assertion behaviour in edge cases. The Pest --parallel sealed event facade fix indicates version-sensitive behaviour in parallel runs. The mbstring-less config fix reduces environment risk.

Key questions: Which Laravel, PHP, PHPUnit, and Pest versions are supported? Do we rely on PSR-7/Symfony HTTP clients, or Laravel’s HTTP client only? How are OpenAPI/spec files currently sourced and versioned? Will consumer-side contract fakes replace existing mocked HTTP tests? Who owns gesso.php and coverage gates? What is the deprecation timeline for Fuzz → Contract? Are form/multipart validation changes expected to affect current API tests?

Integration Approach

Stack fit: Strong for Laravel teams already using PHPUnit/Pest and CI-based API tests. Gesso sits alongside existing test suites rather than replacing them. The Laravel config integration and route-side parity exclusions are especially relevant for apps with many routes and generated specs. PSR-7/Symfony adapter defaults matter only if the team tests non-Laravel HTTP clients or shared PHP services.

Migration path: Treat v2.7.0 as a controlled minor upgrade. First upgrade in a branch and run doctor --emit-config to baseline a gesso.php. Diff that against existing PHPUnit and Laravel configuration, then consolidate to the shared config model. Migrate named contract checks to the Contract namespace while the Fuzz alias is still available. Adopt --format and --output-file in CI scripts incrementally, then enable coverage:merge and coverage:gate defaults via --config. Finally, enable route-side parity exclusions and spec lists from config.

Compatibility: Check Pest parallel runs and PHPStan/static-analysis jobs first, because v2.7.0 includes fixes in both areas. Validate environments without ext-mbstring; the release includes a fallback. Re-run form-encoded, multipart, and JSON-body contract tests because validation semantics changed. Confirm that existing test scripts tolerate new global CLI flags and config-driven defaults.

Sequencing: 1) Upgrade in a non-blocking CI job. 2) Generate and review gesso.php. 3) Consolidate PHPUnit/Laravel config. 4) Migrate Fuzz contract references to Contract. 5) Update CI output/reporting flags. 6) Enable coverage gates. 7) Adopt route parity exclusions and spec lists. 8) Make contract checks a required CI gate after a stabilisation period.

Operational Impact

Maintenance: Low-to-moderate. The package is test/CI tooling, so production runtime risk is limited, but config surface is growing. Teams should pin minor versions, track the Fuzz deprecation, and review gesso.php changes like application config. Shared PHPUnit/Laravel config reduces duplication but creates a single point of failure if misconfigured.

Support: The doctor command and --emit-config materially improve supportability and onboarding. Still, internal ownership is needed for spec sources, route exclusions, coverage thresholds, and CI reporting. Document the expected CLI invocation and config ownership before broad rollout.

Scaling: Good for multi-route Laravel applications and parallel test suites. The enum-drift change to evaluate once per Paratest run avoids repeated work. Centralised coverage merge/gate configuration helps standardise quality gates across teams. Consumer-side fakes improve scalability of contract testing by removing live-provider dependencies. Watch CI runtime as validation and doctor checks expand.

Failure modes: Config drift between PHPUnit and Laravel; Fuzz alias removal breaking tests later; form-encoded/multipart assertion changes after validation updates; JSON body decoding changes for nested {}; Pest parallel incompatibilities on older versions; missing mbstring on minimal CI images; CI scripts broken by new global flags or config-driven defaults; coverage gates failing due to changed merge behaviour.

Ramp-up: Moderate. Developers familiar with PHPUnit/Pest will adopt quickly, but contract-testing concepts, spec ownership, and CLI reporting need explanation. Use doctor --emit-config as the onboarding baseline, run a pilot on one API surface, and publish a short runbook covering config, namespace migration, and CI gate expectations.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
elmogy/larafast
xeviant/laravel-paystack
gorilladash/laravel-website-sdk
martialbe/flysystem-oss
chondal/3312client
jeroen-g/flickr
opscale-co/nova-genbi
itsjustvita/laravel-retention
tequilarapido/trackit
gregsphotography/site-builder-filament
cabaoctavio/laravel-query-log
gregsphotography/site-builder-components
io-digital/clickatell
snowsoft/laravel-admin
oxygen/auth
relicsoftware/barakah-payment-gateway
tobya/work-with-composer
equipc/laravel-email-validator
equipc/laravel-email-database-log
adedsec/nova-translated-labels