mirror of
https://github.com/elyby/oauth2-server.git
synced 2024-11-15 09:47:46 +05:30
16 lines
570 B
PHP
16 lines
570 B
PHP
<?php
|
|
$I = new ApiTester($scenario);
|
|
$I->wantTo('get an access token using the client credentials grant, missing client id');
|
|
$I->sendPOST(
|
|
'client_credentials.php/access_token',
|
|
[
|
|
'grant_type' => 'client_credentials'
|
|
]
|
|
);
|
|
$I->canSeeResponseCodeIs(400);
|
|
$I->canSeeResponseIsJson();
|
|
$I->seeResponseContainsJson([
|
|
'error' => 'invalid_request',
|
|
'message' => 'The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed. Check the "client_id" parameter.'
|
|
]);
|