+ $this->assertSame($this->routerMock->generate('homepage'), $redirectUrl);
+ }
+
+ public function testUserForRedirectWithIgnoreActionMarkAsRead()
+ {
+ $this->token->getUser()->getConfig()->setActionMarkAsRead(Config::REDIRECT_TO_HOMEPAGE);
+
+ $redirectUrl = $this->redirect->to('/unread/list', '', true);
+
+ $this->assertSame('/unread/list', $redirectUrl);
+ }
+
+ public function testUserForRedirectNullWithFallbackWithIgnoreActionMarkAsRead()
+ {
+ $this->token->getUser()->getConfig()->setActionMarkAsRead(Config::REDIRECT_TO_HOMEPAGE);
+
+ $redirectUrl = $this->redirect->to(null, 'fallback', true);
+
+ $this->assertSame('fallback', $redirectUrl);