X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=tests%2Fapi%2Fcontrollers%2Flinks%2FGetLinksTest.php;h=ca1bfc6362d550de19805938f397938344f409f7;hb=a5a9cf23acd1248585173aa32757d9720b5f2d62;hp=4e2d55ac2f4fe89ff90ed5e560ec9f5d70787ffb;hpb=3fb29fdda04ca86e04422d49b86cf646d53c4f9d;p=github%2Fshaarli%2FShaarli.git diff --git a/tests/api/controllers/links/GetLinksTest.php b/tests/api/controllers/links/GetLinksTest.php index 4e2d55ac..ca1bfc63 100644 --- a/tests/api/controllers/links/GetLinksTest.php +++ b/tests/api/controllers/links/GetLinksTest.php @@ -20,7 +20,7 @@ use Slim\Http\Response; * * @package Shaarli\Api\Controllers */ -class GetLinksTest extends \PHPUnit\Framework\TestCase +class GetLinksTest extends \Shaarli\TestCase { /** * @var string datastore to test write operations @@ -55,7 +55,7 @@ class GetLinksTest extends \PHPUnit\Framework\TestCase /** * Before every test, instantiate a new Api with its config, plugins and bookmarks. */ - public function setUp() + protected function setUp(): void { $this->conf = new ConfigManager('tests/utils/config/configJson'); $this->conf->set('resource.datastore', self::$testDatastore); @@ -74,7 +74,7 @@ class GetLinksTest extends \PHPUnit\Framework\TestCase /** * After every test, remove the test datastore. */ - public function tearDown() + protected function tearDown(): void { @unlink(self::$testDatastore); } @@ -109,7 +109,7 @@ class GetLinksTest extends \PHPUnit\Framework\TestCase // Check first element fields $first = $data[2]; - $this->assertEquals('http://domain.tld/?WDWyig', $first['url']); + $this->assertEquals('http://domain.tld/shaare/WDWyig', $first['url']); $this->assertEquals('WDWyig', $first['shorturl']); $this->assertEquals('Link title: @website', $first['title']); $this->assertEquals(