1
0
Fork 0
mirror of https://github.com/wallabag/wallabag.git synced 2025-06-27 16:36:00 +00:00
wallabag/tests/Controller/Import/ImportControllerTest.php

29 lines
782 B
PHP
Raw Normal View History

<?php
2024-02-19 01:30:12 +01:00
namespace Tests\Wallabag\Controller\Import;
use Tests\Wallabag\WallabagTestCase;
class ImportControllerTest extends WallabagTestCase
{
public function testLogin()
{
$client = $this->getTestClient();
$client->request('GET', '/import/');
2017-07-01 09:52:38 +02:00
$this->assertSame(302, $client->getResponse()->getStatusCode());
2020-06-15 13:37:50 +02:00
$this->assertStringContainsString('login', $client->getResponse()->headers->get('location'));
}
public function testImportList()
{
$this->logInAs('admin');
$client = $this->getTestClient();
$crawler = $client->request('GET', '/import/');
2017-07-01 09:52:38 +02:00
$this->assertSame(200, $client->getResponse()->getStatusCode());
2025-06-05 00:21:05 +02:00
$this->assertSame(14, $crawler->filter('.card-title')->count());
}
}