Download the PHP package vincentchalamon/api-extension without Composer
On this page you can find all versions of the php package vincentchalamon/api-extension. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download vincentchalamon/api-extension
More information about vincentchalamon/api-extension
Files in vincentchalamon/api-extension
Package api-extension
Short Description Behat extension for API Platform
License MIT
Informations about the package api-extension
ApiExtension
This Behat extension requires following extensions, check their documentations for installation & usage:
This extension is just a shortcut to write some steps, it doesn't replace your custom steps. For instance, if you
want to test that updating a user updates its password, you still need to add a customer step like
And the user password has been successfully updated
.
Install
Declare required extensions in your Behat configuration:
Using custom guessers for populator
Usage with Symfony FrameworkBundle < 4.1
Running with Symfony FrameworkBundle < 4.1, you need to override some private services:
Usage
FixturesContext provides the following steps:
the following <name>
there is <nb> <name>
there is a <name>
there is an <name>
there are <nb> <name>
there are <name>
there are <nb> <name> with:
ApiContext provides the following steps:
I get a list of <name>
I get a list of <name> filtered by <filter>
I get a list of <name> ordered by <filter>
I create a <name>
I create an <name>
I create a <name> using group <serialization-group>
I create a <name> using groups <serialization-groups>
I create an <name> using group <serialization-group>
I create an <name> using groups <serialization-groups>
I create a <name> with:
I create an <name> with:
I create a <name> using group <serialization-group> with:
I create a <name> using groups <serialization-groups> with:
I create an <name> using group <serialization-group> with:
I create an <name> using groups <serialization-groups> with:
I get a <name>
I get an <name>
I get the <name> <value>
I delete a <name>
I delete an <name>
I delete the <name> <value>
I update a <name>
I update an <name>
I update the <name> <value>
I update a <name> with:
I update an <name> with:
I update the <name> <value> with:
the request is invalid
the <name> is not found
the method is not allowed
I see a <name>
I see an <name>
I see a list of <name>
I see a list of <nb> <name>
I don't see any <name>
print <name> list JSON schema
print <name> item JSON schema
print last JSON request
Example:
Add faker provider
To use a custom faker provider from fzaninotto/Faker, update your Behat configuration as following:
All versions of api-extension with dependencies
api-platform/core Version ^2.2
behat/behat Version ^3.4.3
behat/mink-extension Version ^2.3
behat/symfony2-extension Version ^2.1.4
behatch/contexts Version ^3.0
doctrine/common Version ^2.7
doctrine/doctrine-cache-bundle Version ^1.3.1
doctrine/orm Version ^2.5
fzaninotto/faker Version ^1.7
psr/container Version ^1.0
symfony/config Version ^3.4 || ^4.0
symfony/dependency-injection Version ^3.4 || ^4.0
symfony/doctrine-bridge Version ^2.8 || ^3.0 || ^4.0
symfony/http-kernel Version ^3.4 || ^4.0
symfony/property-info Version ^3.4 || ^4.0
symfony/validator Version ^3.4 || ^4.0