mirror of
https://github.com/wallabag/wallabag.git
synced 2025-09-15 18:57:05 +00:00
Move LoginFormAuthenticator directly in SiteConfig namespace
This commit is contained in:
parent
ac6969f4cc
commit
0fdcbcf7fb
4 changed files with 9 additions and 10 deletions
|
@ -1,13 +1,13 @@
|
|||
<?php
|
||||
|
||||
namespace Tests\Wallabag\SiteConfig\Authenticator;
|
||||
namespace Tests\Wallabag\SiteConfig;
|
||||
|
||||
use GuzzleHttp\Client;
|
||||
use GuzzleHttp\Message\Response;
|
||||
use GuzzleHttp\Stream\Stream;
|
||||
use GuzzleHttp\Subscriber\Mock;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Wallabag\SiteConfig\Authenticator\LoginFormAuthenticator;
|
||||
use Wallabag\SiteConfig\LoginFormAuthenticator;
|
||||
use Wallabag\SiteConfig\SiteConfig;
|
||||
|
||||
class LoginFormAuthenticatorTest extends TestCase
|
||||
|
@ -80,7 +80,7 @@ class LoginFormAuthenticatorTest extends TestCase
|
|||
|
||||
$response->expects($this->any())
|
||||
->method('getBody')
|
||||
->willReturn(file_get_contents(__DIR__ . '/../../fixtures/aoc.media.html'));
|
||||
->willReturn(file_get_contents(__DIR__ . '/../fixtures/aoc.media.html'));
|
||||
|
||||
$response->expects($this->any())
|
||||
->method('getStatusCode')
|
||||
|
@ -142,7 +142,7 @@ class LoginFormAuthenticatorTest extends TestCase
|
|||
|
||||
$response->expects($this->any())
|
||||
->method('getBody')
|
||||
->willReturn(file_get_contents(__DIR__ . '/../../fixtures/nextinpact-login.html'));
|
||||
->willReturn(file_get_contents(__DIR__ . '/../fixtures/nextinpact-login.html'));
|
||||
|
||||
$response->expects($this->any())
|
||||
->method('getStatusCode')
|
||||
|
@ -211,7 +211,7 @@ class LoginFormAuthenticatorTest extends TestCase
|
|||
]);
|
||||
|
||||
$auth = new LoginFormAuthenticator();
|
||||
$loginRequired = $auth->isLoginRequired($siteConfig, file_get_contents(__DIR__ . '/../../fixtures/nextinpact-login.html'));
|
||||
$loginRequired = $auth->isLoginRequired($siteConfig, file_get_contents(__DIR__ . '/../fixtures/nextinpact-login.html'));
|
||||
|
||||
$this->assertFalse($loginRequired);
|
||||
}
|
||||
|
@ -228,7 +228,7 @@ class LoginFormAuthenticatorTest extends TestCase
|
|||
]);
|
||||
|
||||
$auth = new LoginFormAuthenticator();
|
||||
$loginRequired = $auth->isLoginRequired($siteConfig, file_get_contents(__DIR__ . '/../../fixtures/nextinpact-article.html'));
|
||||
$loginRequired = $auth->isLoginRequired($siteConfig, file_get_contents(__DIR__ . '/../fixtures/nextinpact-article.html'));
|
||||
|
||||
$this->assertTrue($loginRequired);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue