aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/api/controllers/links/GetLinkIdTest.php
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2020-10-13 12:07:13 +0200
committerArthurHoaro <arthur@hoa.ro>2020-10-13 12:07:13 +0200
commitd9f6275ebca035fec8331652c677981056793ccc (patch)
tree37a64baf4f0eba6b781040605965383d8aded2cc /tests/api/controllers/links/GetLinkIdTest.php
parent38672ba0d1c722e5d6d33a58255ceb55e9410e46 (diff)
parentd63ff87a009313141ae684ec447b902562ff6ee7 (diff)
downloadShaarli-d9f6275ebca035fec8331652c677981056793ccc.tar.gz
Shaarli-d9f6275ebca035fec8331652c677981056793ccc.tar.zst
Shaarli-d9f6275ebca035fec8331652c677981056793ccc.zip
Merge branch 'v0.11' into stablestable
Diffstat (limited to 'tests/api/controllers/links/GetLinkIdTest.php')
-rw-r--r--tests/api/controllers/links/GetLinkIdTest.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/api/controllers/links/GetLinkIdTest.php b/tests/api/controllers/links/GetLinkIdTest.php
index 57528d5a..cb9b7f6a 100644
--- a/tests/api/controllers/links/GetLinkIdTest.php
+++ b/tests/api/controllers/links/GetLinkIdTest.php
@@ -3,7 +3,6 @@
3namespace Shaarli\Api\Controllers; 3namespace Shaarli\Api\Controllers;
4 4
5use Shaarli\Config\ConfigManager; 5use Shaarli\Config\ConfigManager;
6
7use Slim\Container; 6use Slim\Container;
8use Slim\Http\Environment; 7use Slim\Http\Environment;
9use Slim\Http\Request; 8use Slim\Http\Request;
@@ -18,7 +17,7 @@ use Slim\Http\Response;
18 * 17 *
19 * @package Shaarli\Api\Controllers 18 * @package Shaarli\Api\Controllers
20 */ 19 */
21class GetLinkIdTest extends \PHPUnit_Framework_TestCase 20class GetLinkIdTest extends \PHPUnit\Framework\TestCase
22{ 21{
23 /** 22 /**
24 * @var string datastore to test write operations 23 * @var string datastore to test write operations
@@ -61,7 +60,7 @@ class GetLinkIdTest extends \PHPUnit_Framework_TestCase
61 60
62 $this->container = new Container(); 61 $this->container = new Container();
63 $this->container['conf'] = $this->conf; 62 $this->container['conf'] = $this->conf;
64 $this->container['db'] = new \LinkDB(self::$testDatastore, true, false); 63 $this->container['db'] = new \Shaarli\Bookmark\LinkDB(self::$testDatastore, true, false);
65 $this->container['history'] = null; 64 $this->container['history'] = null;
66 65
67 $this->controller = new Links($this->container); 66 $this->controller = new Links($this->container);
@@ -108,7 +107,7 @@ class GetLinkIdTest extends \PHPUnit_Framework_TestCase
108 $this->assertEquals('sTuff', $data['tags'][0]); 107 $this->assertEquals('sTuff', $data['tags'][0]);
109 $this->assertEquals(false, $data['private']); 108 $this->assertEquals(false, $data['private']);
110 $this->assertEquals( 109 $this->assertEquals(
111 \DateTime::createFromFormat(\LinkDB::LINK_DATE_FORMAT, '20150310_114651')->format(\DateTime::ATOM), 110 \DateTime::createFromFormat(\Shaarli\Bookmark\LinkDB::LINK_DATE_FORMAT, '20150310_114651')->format(\DateTime::ATOM),
112 $data['created'] 111 $data['created']
113 ); 112 );
114 $this->assertEmpty($data['updated']); 113 $this->assertEmpty($data['updated']);