diff options
author | VirtualTam <virtualtam@flibidi.net> | 2017-03-03 23:06:12 +0100 |
---|---|---|
committer | VirtualTam <virtualtam@flibidi.net> | 2017-03-04 17:07:52 +0100 |
commit | 3c66e56435359dc678048193e8ee239d06f79b64 (patch) | |
tree | 38a4be4a9d9babc193683feec412ac008ca9a169 /tests/api/controllers/GetLinkIdTest.php | |
parent | 74198dcdf65ee3dd83cbe5b6a8a85bc386a62063 (diff) | |
download | Shaarli-3c66e56435359dc678048193e8ee239d06f79b64.tar.gz Shaarli-3c66e56435359dc678048193e8ee239d06f79b64.tar.zst Shaarli-3c66e56435359dc678048193e8ee239d06f79b64.zip |
application: introduce the Shaarli\Config namespace
Namespaces have been introduced with the REST API, and should be generalized
to the whole codebase to manage object scope and benefit from autoloading.
See:
- https://secure.php.net/manual/en/language.namespaces.php
- http://www.php-fig.org/psr/psr-4/
Signed-off-by: VirtualTam <virtualtam@flibidi.net>
Diffstat (limited to 'tests/api/controllers/GetLinkIdTest.php')
-rw-r--r-- | tests/api/controllers/GetLinkIdTest.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/api/controllers/GetLinkIdTest.php b/tests/api/controllers/GetLinkIdTest.php index 1b020505..45b18e6a 100644 --- a/tests/api/controllers/GetLinkIdTest.php +++ b/tests/api/controllers/GetLinkIdTest.php | |||
@@ -2,6 +2,7 @@ | |||
2 | 2 | ||
3 | namespace Shaarli\Api\Controllers; | 3 | namespace Shaarli\Api\Controllers; |
4 | 4 | ||
5 | use Shaarli\Config\ConfigManager; | ||
5 | 6 | ||
6 | use Slim\Container; | 7 | use Slim\Container; |
7 | use Slim\Http\Environment; | 8 | use Slim\Http\Environment; |
@@ -25,7 +26,7 @@ class GetLinkIdTest extends \PHPUnit_Framework_TestCase | |||
25 | protected static $testDatastore = 'sandbox/datastore.php'; | 26 | protected static $testDatastore = 'sandbox/datastore.php'; |
26 | 27 | ||
27 | /** | 28 | /** |
28 | * @var \ConfigManager instance | 29 | * @var ConfigManager instance |
29 | */ | 30 | */ |
30 | protected $conf; | 31 | protected $conf; |
31 | 32 | ||
@@ -54,7 +55,7 @@ class GetLinkIdTest extends \PHPUnit_Framework_TestCase | |||
54 | */ | 55 | */ |
55 | public function setUp() | 56 | public function setUp() |
56 | { | 57 | { |
57 | $this->conf = new \ConfigManager('tests/utils/config/configJson'); | 58 | $this->conf = new ConfigManager('tests/utils/config/configJson'); |
58 | $this->refDB = new \ReferenceLinkDB(); | 59 | $this->refDB = new \ReferenceLinkDB(); |
59 | $this->refDB->write(self::$testDatastore); | 60 | $this->refDB->write(self::$testDatastore); |
60 | 61 | ||