mirror of
https://github.com/wallabag/wallabag.git
synced 2024-12-16 10:22:14 +01:00
Fix tests
This commit is contained in:
parent
769e19dc4a
commit
9744e97131
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Wallabag\CoreBundle\Tests\Controller;
|
||||
namespace Wallabag\ApiBundle\Tests\Controller;
|
||||
|
||||
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
||||
|
||||
@ -177,10 +177,10 @@ class WallabagRestControllerTest extends WebTestCase
|
||||
$content = json_decode($client->getResponse()->getContent(), true);
|
||||
|
||||
$this->assertGreaterThanOrEqual(1, count($content));
|
||||
$this->assertEmpty($content['_embedded']['items']);
|
||||
$this->assertEquals(0, $content['total']);
|
||||
$this->assertNotEmpty($content['_embedded']['items']);
|
||||
$this->assertGreaterThanOrEqual(1, $content['total']);
|
||||
$this->assertEquals(1, $content['page']);
|
||||
$this->assertEquals(1, $content['pages']);
|
||||
$this->assertGreaterThanOrEqual(1, $content['pages']);
|
||||
|
||||
$this->assertTrue(
|
||||
$client->getResponse()->headers->contains(
|
||||
|
@ -133,7 +133,7 @@ class ConfigController extends Controller
|
||||
'rss' => array(
|
||||
'username' => $user->getUsername(),
|
||||
'token' => $config->getRssToken(),
|
||||
)
|
||||
),
|
||||
));
|
||||
}
|
||||
|
||||
|
@ -397,7 +397,7 @@ class ConfigControllerTest extends WallabagCoreTestCase
|
||||
);
|
||||
|
||||
$this->assertEquals(200, $client->getResponse()->getStatusCode());
|
||||
$content = json_decode($client->getResponse()->getContent(), true);;
|
||||
$content = json_decode($client->getResponse()->getContent(), true);
|
||||
$this->assertArrayHasKey('token', $content);
|
||||
}
|
||||
|
||||
|
@ -2,9 +2,9 @@
|
||||
|
||||
namespace Wallabag\CoreBundle\Tests\Controller;
|
||||
|
||||
use Wallabag\CoreBundle\Tests\WallabagTestCase;
|
||||
use Wallabag\CoreBundle\Tests\WallabagCoreTestCase;
|
||||
|
||||
class RssControllerTest extends WallabagTestCase
|
||||
class RssControllerTest extends WallabagCoreTestCase
|
||||
{
|
||||
public function validateDom($xml, $nb = null)
|
||||
{
|
||||
@ -36,13 +36,13 @@ class RssControllerTest extends WallabagTestCase
|
||||
{
|
||||
return array(
|
||||
array(
|
||||
'/admin/YZIOAUZIAO/unread.xml'
|
||||
'/admin/YZIOAUZIAO/unread.xml',
|
||||
),
|
||||
array(
|
||||
'/wallace/YZIOAUZIAO/starred.xml'
|
||||
'/wallace/YZIOAUZIAO/starred.xml',
|
||||
),
|
||||
array(
|
||||
'/wallace/YZIOAUZIAO/archives.xml'
|
||||
'/wallace/YZIOAUZIAO/archives.xml',
|
||||
),
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user