PHP Class Crud\Test\TestCase\Action\AddActionTest

Inheritance: extends Crud\TestSuite\IntegrationTestCase
Afficher le fichier Open project: friendsofcake/crud

Méthodes publiques

Свойство Type Description
$fixtures array fixtures property
$tableClass string Table class to mock on

Méthodes publiques

Méthode Description
apiGetHttpMethodProvider ( ) : array Data provider with GET and DELETE verbs
apiUpdateHttpMethodProvider ( ) : array Data provider with PUT and POST verbs
testActionGet ( ) : void Test the normal HTTP GET flow of _get
testActionGetWithQueryArgs ( ) : void Test the normal HTTP GET flow of _get with query args
testActionPost ( ) : void Test POST will create a record
testActionPostErrorSave ( ) : void Test POST with unsuccessful save()
testActionPostValidationErrors ( ) : void Test POST with validation errors
testActionPostWithAddRedirect ( ) : void Test POST will create a record and redirect to /blogs/add again if _POST['_add'] is present
testActionPostWithEditRedirect ( ) : void Test POST will create a record and redirect to /blogs/edit/$id if _POST['_edit'] is present
testApiCreate ( string $method ) : void Test POST & PUT verbs using API Listener
testApiCreateError ( string $method ) : void Test POST & PUT verbs using API Listener with data validation error
testApiCreateErrors ( string $method ) : void Test POST & PUT verbs using API Listener with data validation errors
testApiGet ( string $method ) : void Test HTTP & DELETE verbs using API Listener

Method Details

apiGetHttpMethodProvider() public méthode

Data provider with GET and DELETE verbs
public apiGetHttpMethodProvider ( ) : array
Résultat array

apiUpdateHttpMethodProvider() public méthode

Data provider with PUT and POST verbs
public apiUpdateHttpMethodProvider ( ) : array
Résultat array

testActionGet() public méthode

Test the normal HTTP GET flow of _get
public testActionGet ( ) : void
Résultat void

testActionGetWithQueryArgs() public méthode

Providing ?name=test should fill out the value in the 'name' input field
public testActionGetWithQueryArgs ( ) : void
Résultat void

testActionPost() public méthode

Test POST will create a record
public testActionPost ( ) : void
Résultat void

testActionPostErrorSave() public méthode

Test POST with unsuccessful save()
public testActionPostErrorSave ( ) : void
Résultat void

testActionPostValidationErrors() public méthode

Test POST with validation errors
public testActionPostValidationErrors ( ) : void
Résultat void

testActionPostWithAddRedirect() public méthode

Test POST will create a record and redirect to /blogs/add again if _POST['_add'] is present
public testActionPostWithAddRedirect ( ) : void
Résultat void

testActionPostWithEditRedirect() public méthode

Test POST will create a record and redirect to /blogs/edit/$id if _POST['_edit'] is present
public testActionPostWithEditRedirect ( ) : void
Résultat void

testApiCreate() public méthode

Test POST & PUT verbs using API Listener
public testApiCreate ( string $method ) : void
$method string
Résultat void

testApiCreateError() public méthode

Test POST & PUT verbs using API Listener with data validation error
public testApiCreateError ( string $method ) : void
$method string
Résultat void

testApiCreateErrors() public méthode

Test POST & PUT verbs using API Listener with data validation errors
public testApiCreateErrors ( string $method ) : void
$method string
Résultat void

testApiGet() public méthode

Test HTTP & DELETE verbs using API Listener
public testApiGet ( string $method ) : void
$method string
Résultat void

Property Details

$fixtures public_oe property

fixtures property
public array $fixtures
Résultat array

$tableClass public_oe property

Table class to mock on
public string $tableClass
Résultat string