]> git.immae.eu Git - github/shaarli/Shaarli.git/blobdiff - tests/plugins/PluginIssoTest.php
Merge pull request #1505 from shaarli/dependabot/npm_and_yarn/lodash-4.17.19
[github/shaarli/Shaarli.git] / tests / plugins / PluginIssoTest.php
index 7aee21974066d74bf51d290fd88341c4992ba9f0..994772051086ae03ebe1602ec0e39cf246f42cdc 100644 (file)
@@ -1,6 +1,8 @@
 <?php
+namespace Shaarli\Plugin\Isso;
 
-use Shaarli\Bookmark\LinkDB;
+use DateTime;
+use Shaarli\Bookmark\Bookmark;
 use Shaarli\Config\ConfigManager;
 use Shaarli\Plugin\PluginManager;
 
@@ -11,7 +13,7 @@ require_once 'plugins/isso/isso.php';
  *
  * Test the Isso plugin (comment system).
  */
-class PluginIssoTest extends PHPUnit_Framework_TestCase
+class PluginIssoTest extends \PHPUnit\Framework\TestCase
 {
     /**
      * Reset plugin path
@@ -58,7 +60,7 @@ class PluginIssoTest extends PHPUnit_Framework_TestCase
                 array(
                     'id' => 12,
                     'url' => $str,
-                    'created' => DateTime::createFromFormat(LinkDB::LINK_DATE_FORMAT, $date),
+                    'created' => DateTime::createFromFormat(Bookmark::LINK_DATE_FORMAT, $date),
                 )
             )
         );
@@ -83,7 +85,7 @@ class PluginIssoTest extends PHPUnit_Framework_TestCase
     }
 
     /**
-     * Test isso plugin when multiple links are displayed (shouldn't be displayed).
+     * Test isso plugin when multiple bookmarks are displayed (shouldn't be displayed).
      */
     public function testIssoMultipleLinks()
     {
@@ -100,13 +102,13 @@ class PluginIssoTest extends PHPUnit_Framework_TestCase
                     'id' => 12,
                     'url' => $str,
                     'shorturl' => $short1 = 'abcd',
-                    'created' => DateTime::createFromFormat(LinkDB::LINK_DATE_FORMAT, $date1),
+                    'created' => DateTime::createFromFormat(Bookmark::LINK_DATE_FORMAT, $date1),
                 ),
                 array(
                     'id' => 13,
                     'url' => $str . '2',
                     'shorturl' => $short2 = 'efgh',
-                    'created' => DateTime::createFromFormat(LinkDB::LINK_DATE_FORMAT, $date2),
+                    'created' => DateTime::createFromFormat(Bookmark::LINK_DATE_FORMAT, $date2),
                 ),
             )
         );
@@ -134,7 +136,7 @@ class PluginIssoTest extends PHPUnit_Framework_TestCase
                     'id' => 12,
                     'url' => $str,
                     'shorturl' => $short1 = 'abcd',
-                    'created' => DateTime::createFromFormat(LinkDB::LINK_DATE_FORMAT, $date),
+                    'created' => DateTime::createFromFormat(Bookmark::LINK_DATE_FORMAT, $date),
                 )
             ),
             'search_term' => $str