]> git.immae.eu Git - github/shaarli/Shaarli.git/blobdiff - tests/api/controllers/GetLinksTest.php
Merge pull request #841 from ArthurHoaro/feature/search-no-tag
[github/shaarli/Shaarli.git] / tests / api / controllers / GetLinksTest.php
index 10330cd9a8d845a77f7d623ad92bd6be4f911949..4cb70224ce734318862810e647eabdd52490d452 100644 (file)
@@ -61,6 +61,7 @@ class GetLinksTest extends \PHPUnit_Framework_TestCase
         $this->container = new Container();
         $this->container['conf'] = $this->conf;
         $this->container['db'] = new \LinkDB(self::$testDatastore, true, false);
+        $this->container['history'] = null;
 
         $this->controller = new Links($this->container);
     }
@@ -94,7 +95,7 @@ class GetLinksTest extends \PHPUnit_Framework_TestCase
         $this->assertEquals($this->refDB->countLinks(), count($data));
 
         // Check order
-        $order = [41, 8, 6, 7, 0, 1, 4, 42];
+        $order = [41, 8, 6, 7, 0, 1, 9, 4, 42];
         $cpt = 0;
         foreach ($data as $link) {
             $this->assertEquals(self::NB_FIELDS_LINK, count($link));
@@ -163,7 +164,7 @@ class GetLinksTest extends \PHPUnit_Framework_TestCase
         $data = json_decode((string) $response->getBody(), true);
         $this->assertEquals($this->refDB->countLinks(), count($data));
         // Check order
-        $order = [41, 8, 6, 7, 0, 1, 4, 42];
+        $order = [41, 8, 6, 7, 0, 1, 9, 4, 42];
         $cpt = 0;
         foreach ($data as $link) {
             $this->assertEquals(self::NB_FIELDS_LINK, count($link));