Download the PHP package mathrix-education/openapi-assertions without Composer
On this page you can find all versions of the php package mathrix-education/openapi-assertions. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download mathrix-education/openapi-assertions
More information about mathrix-education/openapi-assertions
Files in mathrix-education/openapi-assertions
Package openapi-assertions
Short Description Validate PSR-7 requests against OpenAPI specification. Heavily based on league/openapi-psr7-validator.
License MIT
Homepage https://github.com/mathrix-education/openapi-assertions
Informations about the package openapi-assertions
mathrix-education/openapi-assertions
Base library of all Mathrix Education SA PHP projects.
Allow to test API responses against an OpenAPI v3 specification. Proudly maintained by Mathieu Bour [email protected], Vice-CTO.
The library heavily relies on league/openapi-psr7-validator formerly lezhnev74/openapi-psr7-validator.
Lumen
In order to use OpenAPI assertions with lumen, you need to install symfony/psr-http-message-bridge and nyholm/psr7. You can do it with:
Then, add the LumenOpenAPIAssertions trait to your base TestCase, like so:
Usage
To test that an Illuminate Response matches the specification, simply run:
All versions of openapi-assertions with dependencies
phpunit/phpunit Version ^7.0 || ^8.0
league/openapi-psr7-validator Version ^0.5.1