mirror of
https://github.com/elyby/oauth2-server.git
synced 2024-12-29 16:30:44 +05:30
Fix for broken test which wasn't actually broken but was
This commit is contained in:
parent
115237bc1a
commit
2b76e2bf6e
@ -9,6 +9,7 @@ use League\OAuth2\Server\Repositories\ClientRepositoryInterface;
|
|||||||
use League\OAuth2\Server\Repositories\ScopeRepositoryInterface;
|
use League\OAuth2\Server\Repositories\ScopeRepositoryInterface;
|
||||||
use League\OAuth2\Server\Repositories\UserRepositoryInterface;
|
use League\OAuth2\Server\Repositories\UserRepositoryInterface;
|
||||||
use League\OAuth2\Server\ResponseTypes\HtmlResponse;
|
use League\OAuth2\Server\ResponseTypes\HtmlResponse;
|
||||||
|
use League\OAuth2\Server\ResponseTypes\RedirectResponse;
|
||||||
use LeagueTests\Stubs\ClientEntity;
|
use LeagueTests\Stubs\ClientEntity;
|
||||||
use LeagueTests\Stubs\CryptTraitStub;
|
use LeagueTests\Stubs\CryptTraitStub;
|
||||||
use LeagueTests\Stubs\StubResponseType;
|
use LeagueTests\Stubs\StubResponseType;
|
||||||
@ -55,10 +56,6 @@ class ImplicitGrantTest extends \PHPUnit_Framework_TestCase
|
|||||||
$this->assertTrue($grant->canRespondToRequest($request));
|
$this->assertTrue($grant->canRespondToRequest($request));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @expectedException \League\OAuth2\Server\Exception\OAuthServerException
|
|
||||||
* @expectedExceptionCode 9
|
|
||||||
*/
|
|
||||||
public function testRespondToAuthorizationRequest()
|
public function testRespondToAuthorizationRequest()
|
||||||
{
|
{
|
||||||
$client = new ClientEntity();
|
$client = new ClientEntity();
|
||||||
@ -106,7 +103,9 @@ class ImplicitGrantTest extends \PHPUnit_Framework_TestCase
|
|||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
$grant->respondToRequest($request, new StubResponseType(), new \DateInterval('PT10M'));
|
$response = $grant->respondToRequest($request, new StubResponseType(), new \DateInterval('PT10M'));
|
||||||
|
|
||||||
|
$this->assertTrue($response instanceof RedirectResponse);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user