- $this->sessionManager = new SessionManager($this->session, $this->configManager);
- $this->loginManager = new LoginManager($this->configManager, $this->sessionManager);
+ $this->cookieManager = $this->createMock(CookieManager::class);
+ $this->cookieManager->method('getCookieParameter')->willReturnCallback(function (string $key) {
+ return $this->cookie[$key] ?? null;
+ });
+ $this->sessionManager = new SessionManager($this->session, $this->configManager, 'session_path');
+ $this->loginManager = new LoginManager($this->configManager, $this->sessionManager, $this->cookieManager);