Added tests

This commit is contained in:
Nicolas Lœuillet 2020-04-20 19:21:35 +02:00 committed by Jeremy Benoist
parent dce50ddb79
commit 0aeaf0e8c2
No known key found for this signature in database
GPG key ID: BCA73962457ACC3C

View file

@ -411,6 +411,16 @@ class EntryControllerTest extends WallabagCoreTestCase
$this->assertSame(200, $client->getResponse()->getStatusCode());
}
public function testWithAnnotations()
{
$this->logInAs('admin');
$client = $this->getClient();
$client->request('GET', '/with_annotations/list');
$this->assertSame(200, $client->getResponse()->getStatusCode());
}
public function testRangeException()
{
$this->logInAs('admin');
@ -1590,6 +1600,10 @@ class EntryControllerTest extends WallabagCoreTestCase
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('/view/', $client->getResponse()->getTargetUrl(), 'Untagged random');
$client->request('GET', '/with_annotations/random');
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertContains('/view/', $client->getResponse()->getTargetUrl(), 'With annotations random');
$client->request('GET', '/all/random');
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('/view/', $client->getResponse()->getTargetUrl(), 'All random');