mirror of
https://github.com/wallabag/wallabag.git
synced 2024-11-26 11:01:04 +00:00
Merge pull request #6813 from yguedidi/replace-client-by-kernelbrowser
Replace Client by KernelBrowser
This commit is contained in:
commit
815158fefa
4 changed files with 11 additions and 11 deletions
|
@ -5,7 +5,7 @@ namespace Tests\Wallabag\AnnotationBundle;
|
|||
use FOS\UserBundle\Model\UserInterface;
|
||||
use FOS\UserBundle\Model\UserManager;
|
||||
use FOS\UserBundle\Security\LoginManager;
|
||||
use Symfony\Bundle\FrameworkBundle\Client;
|
||||
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
|
||||
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
||||
use Symfony\Component\BrowserKit\Cookie;
|
||||
use Symfony\Component\HttpFoundation\Session\SessionInterface;
|
||||
|
@ -14,7 +14,7 @@ use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInt
|
|||
abstract class WallabagAnnotationTestCase extends WebTestCase
|
||||
{
|
||||
/**
|
||||
* @var Client
|
||||
* @var KernelBrowser
|
||||
*/
|
||||
protected $client = null;
|
||||
|
||||
|
@ -42,7 +42,7 @@ abstract class WallabagAnnotationTestCase extends WebTestCase
|
|||
}
|
||||
|
||||
/**
|
||||
* @return Client
|
||||
* @return KernelBrowser
|
||||
*/
|
||||
protected function createAuthorizedClient()
|
||||
{
|
||||
|
|
|
@ -6,7 +6,7 @@ use Doctrine\ORM\EntityManagerInterface;
|
|||
use FOS\UserBundle\Model\UserInterface;
|
||||
use FOS\UserBundle\Model\UserManager;
|
||||
use FOS\UserBundle\Security\LoginManager;
|
||||
use Symfony\Bundle\FrameworkBundle\Client;
|
||||
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
|
||||
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
||||
use Symfony\Component\BrowserKit\Cookie;
|
||||
use Symfony\Component\HttpFoundation\Session\SessionInterface;
|
||||
|
@ -16,7 +16,7 @@ use Wallabag\UserBundle\Entity\User;
|
|||
abstract class WallabagApiTestCase extends WebTestCase
|
||||
{
|
||||
/**
|
||||
* @var Client
|
||||
* @var KernelBrowser
|
||||
*/
|
||||
protected $client = null;
|
||||
|
||||
|
@ -32,7 +32,7 @@ abstract class WallabagApiTestCase extends WebTestCase
|
|||
}
|
||||
|
||||
/**
|
||||
* @return Client
|
||||
* @return KernelBrowser
|
||||
*/
|
||||
protected function createAuthorizedClient()
|
||||
{
|
||||
|
|
|
@ -4,7 +4,7 @@ namespace Tests\Wallabag\CoreBundle\Controller;
|
|||
|
||||
use Craue\ConfigBundle\Util\Config;
|
||||
use Doctrine\ORM\EntityManagerInterface;
|
||||
use Symfony\Bundle\FrameworkBundle\Client;
|
||||
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
|
||||
use Tests\Wallabag\CoreBundle\WallabagCoreTestCase;
|
||||
use Wallabag\CoreBundle\Entity\SiteCredential;
|
||||
|
||||
|
@ -139,7 +139,7 @@ class SiteCredentialControllerTest extends WallabagCoreTestCase
|
|||
$this->assertStringContainsString('flashes.site_credential.notice.deleted', $crawler->filter('body')->extract(['_text'])[0]);
|
||||
}
|
||||
|
||||
private function createSiteCredential(Client $client)
|
||||
private function createSiteCredential(KernelBrowser $client)
|
||||
{
|
||||
$credential = new SiteCredential($this->getLoggedInUser());
|
||||
$credential->setHost('google.io');
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
namespace Tests\Wallabag\CoreBundle;
|
||||
|
||||
use Doctrine\ORM\EntityManagerInterface;
|
||||
use Symfony\Bundle\FrameworkBundle\Client;
|
||||
use Symfony\Bundle\FrameworkBundle\Console\Application;
|
||||
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
|
||||
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
||||
use Symfony\Component\BrowserKit\Cookie;
|
||||
use Symfony\Component\Console\Input\ArrayInput;
|
||||
|
@ -16,7 +16,7 @@ use Wallabag\UserBundle\Entity\User;
|
|||
abstract class WallabagCoreTestCase extends WebTestCase
|
||||
{
|
||||
/**
|
||||
* @var Client|null
|
||||
* @var KernelBrowser|null
|
||||
*/
|
||||
private $client = null;
|
||||
|
||||
|
@ -41,7 +41,7 @@ abstract class WallabagCoreTestCase extends WebTestCase
|
|||
return $this->client;
|
||||
}
|
||||
|
||||
public function resetDatabase(Client $client)
|
||||
public function resetDatabase(KernelBrowser $client)
|
||||
{
|
||||
$application = new Application($client->getKernel());
|
||||
$application->setAutoExit(false);
|
||||
|
|
Loading…
Reference in a new issue