Skip to content

Commit

Permalink
ren ame LogOutAuth0Adapter to LogOutOAuthAdapter
Browse files Browse the repository at this point in the history
  • Loading branch information
JonasVHG committed Nov 19, 2024
1 parent 7502575 commit 6390662
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions app/ActionServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
use CultuurNet\UDB3\JwtProvider\Infrastructure\Service\ExtractLocaleFromRequest;
use CultuurNet\UDB3\JwtProvider\Infrastructure\Service\IsAllowedRefreshToken;
use CultuurNet\UDB3\JwtProvider\Infrastructure\Service\LoginAuth0Adapter;
use CultuurNet\UDB3\JwtProvider\Infrastructure\Service\LogOutAuth0Adapter;
use CultuurNet\UDB3\JwtProvider\Infrastructure\Service\LogOutOAuthAdapter;
use CultuurNet\UDB3\JwtProvider\Infrastructure\Service\RefreshAuth0Adapter;
use GuzzleHttp\Client;
use Slim\Psr7\Factory\UriFactory;
Expand Down Expand Up @@ -94,7 +94,7 @@ public function register(): void

$this->addShared(
LogOutServiceInterface::class,
fn (): LogOutAuth0Adapter => new LogOutAuth0Adapter(
fn (): LogOutOAuthAdapter => new LogOutOAuthAdapter(
$this->get(Auth0::class),
new Authentication(
[
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
use Psr\Http\Message\UriFactoryInterface;
use Psr\Http\Message\UriInterface;

final class LogOutAuth0Adapter implements LogOutServiceInterface
final class LogOutOAuthAdapter implements LogOutServiceInterface
{
private ResponseFactoryInterface $responseFactory;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
use Prophecy\PhpUnit\ProphecyTrait;
use Slim\Psr7\Factory\UriFactory;

final class LogOutAuth0AdapterTest extends TestCase
final class LogOutOAuthAdapterTest extends TestCase
{
use ProphecyTrait;

Expand All @@ -28,7 +28,7 @@ public function it_logs_out_user(): void

$authentication->getLogoutLink('http://foo-bar.com', ['clientId' => 'client-id'])->willReturn($auth0LogOutUri);

$auth0adapter = new LogOutAuth0Adapter(
$logOutOAuthAdapter = new LogOutOAuthAdapter(
$auth0->reveal(),
$authentication->reveal(),
new SlimResponseFactory(),
Expand All @@ -37,7 +37,7 @@ public function it_logs_out_user(): void
'client-id'
);

$response = $auth0adapter->logout();
$response = $logOutOAuthAdapter->logout();

$this->assertEquals(StatusCodeInterface::STATUS_MOVED_PERMANENTLY, $response->getStatusCode());
$this->assertEquals($auth0LogOutUri, $response->getHeaderLine('Location'));
Expand Down

0 comments on commit 6390662

Please sign in to comment.