diff options
author | ArthurHoaro <arthur@hoa.ro> | 2021-02-04 11:11:33 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-04 11:11:33 +0100 |
commit | 9db1ccdf2ce8381e1f3acb581d3c6a6def095d8c (patch) | |
tree | 97a618b77d327a5f963c91522988e24db5a9e158 /tests/api/controllers/info/InfoTest.php | |
parent | 8997ae6c8e24286f7d47981eaf905e80d2481c10 (diff) | |
parent | bcba6bd353161fab456b423e93571ab027d5423c (diff) | |
download | Shaarli-master.tar.gz Shaarli-master.tar.zst Shaarli-master.zip |
New plugin hook: ability to add custom filters to Shaarli search engine
Diffstat (limited to 'tests/api/controllers/info/InfoTest.php')
-rw-r--r-- | tests/api/controllers/info/InfoTest.php | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/tests/api/controllers/info/InfoTest.php b/tests/api/controllers/info/InfoTest.php index 10b29ab2..2428ca43 100644 --- a/tests/api/controllers/info/InfoTest.php +++ b/tests/api/controllers/info/InfoTest.php | |||
@@ -5,6 +5,7 @@ use malkusch\lock\mutex\NoMutex; | |||
5 | use Shaarli\Bookmark\BookmarkFileService; | 5 | use Shaarli\Bookmark\BookmarkFileService; |
6 | use Shaarli\Config\ConfigManager; | 6 | use Shaarli\Config\ConfigManager; |
7 | use Shaarli\History; | 7 | use Shaarli\History; |
8 | use Shaarli\Plugin\PluginManager; | ||
8 | use Shaarli\TestCase; | 9 | use Shaarli\TestCase; |
9 | use Slim\Container; | 10 | use Slim\Container; |
10 | use Slim\Http\Environment; | 11 | use Slim\Http\Environment; |
@@ -55,12 +56,18 @@ class InfoTest extends TestCase | |||
55 | $this->conf->set('resource.datastore', self::$testDatastore); | 56 | $this->conf->set('resource.datastore', self::$testDatastore); |
56 | $this->refDB = new \ReferenceLinkDB(); | 57 | $this->refDB = new \ReferenceLinkDB(); |
57 | $this->refDB->write(self::$testDatastore); | 58 | $this->refDB->write(self::$testDatastore); |
58 | 59 | $this->pluginManager = new PluginManager($this->conf); | |
59 | $history = new History('sandbox/history.php'); | 60 | $history = new History('sandbox/history.php'); |
60 | 61 | ||
61 | $this->container = new Container(); | 62 | $this->container = new Container(); |
62 | $this->container['conf'] = $this->conf; | 63 | $this->container['conf'] = $this->conf; |
63 | $this->container['db'] = new BookmarkFileService($this->conf, $history, $mutex, true); | 64 | $this->container['db'] = new BookmarkFileService( |
65 | $this->conf, | ||
66 | $this->pluginManager, | ||
67 | $history, | ||
68 | $mutex, | ||
69 | true | ||
70 | ); | ||
64 | $this->container['history'] = null; | 71 | $this->container['history'] = null; |
65 | 72 | ||
66 | $this->controller = new Info($this->container); | 73 | $this->controller = new Info($this->container); |