diff options
Diffstat (limited to 'tests/container/ContainerBuilderTest.php')
-rw-r--r-- | tests/container/ContainerBuilderTest.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/container/ContainerBuilderTest.php b/tests/container/ContainerBuilderTest.php index 9b97ed6d..cc2eb37f 100644 --- a/tests/container/ContainerBuilderTest.php +++ b/tests/container/ContainerBuilderTest.php | |||
@@ -7,6 +7,7 @@ namespace Shaarli\Container; | |||
7 | use PHPUnit\Framework\TestCase; | 7 | use PHPUnit\Framework\TestCase; |
8 | use Shaarli\Bookmark\BookmarkServiceInterface; | 8 | use Shaarli\Bookmark\BookmarkServiceInterface; |
9 | use Shaarli\Config\ConfigManager; | 9 | use Shaarli\Config\ConfigManager; |
10 | use Shaarli\Formatter\FormatterFactory; | ||
10 | use Shaarli\History; | 11 | use Shaarli\History; |
11 | use Shaarli\Render\PageBuilder; | 12 | use Shaarli\Render\PageBuilder; |
12 | use Shaarli\Security\LoginManager; | 13 | use Shaarli\Security\LoginManager; |
@@ -30,7 +31,9 @@ class ContainerBuilderTest extends TestCase | |||
30 | { | 31 | { |
31 | $this->conf = new ConfigManager('tests/utils/config/configJson'); | 32 | $this->conf = new ConfigManager('tests/utils/config/configJson'); |
32 | $this->sessionManager = $this->createMock(SessionManager::class); | 33 | $this->sessionManager = $this->createMock(SessionManager::class); |
34 | |||
33 | $this->loginManager = $this->createMock(LoginManager::class); | 35 | $this->loginManager = $this->createMock(LoginManager::class); |
36 | $this->loginManager->method('isLoggedIn')->willReturn(true); | ||
34 | 37 | ||
35 | $this->containerBuilder = new ContainerBuilder($this->conf, $this->sessionManager, $this->loginManager); | 38 | $this->containerBuilder = new ContainerBuilder($this->conf, $this->sessionManager, $this->loginManager); |
36 | } | 39 | } |
@@ -45,5 +48,6 @@ class ContainerBuilderTest extends TestCase | |||
45 | static::assertInstanceOf(History::class, $container->history); | 48 | static::assertInstanceOf(History::class, $container->history); |
46 | static::assertInstanceOf(BookmarkServiceInterface::class, $container->bookmarkService); | 49 | static::assertInstanceOf(BookmarkServiceInterface::class, $container->bookmarkService); |
47 | static::assertInstanceOf(PageBuilder::class, $container->pageBuilder); | 50 | static::assertInstanceOf(PageBuilder::class, $container->pageBuilder); |
51 | static::assertInstanceOf(FormatterFactory::class, $container->formatterFactory); | ||
48 | } | 52 | } |
49 | } | 53 | } |