Release 1.19.4 (#3255)
* login redirects to homepage if already being logged-in * fix budget check for entries that were moved to another moth * invoice: fix amount should be decimal if decimal template is used * added new month grouped by project/activity/user report
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
namespace App\Tests\Controller\Security;
|
||||
|
||||
use App\Controller\Security\SecurityController;
|
||||
use App\Entity\User;
|
||||
use App\Tests\Controller\ControllerBaseTest;
|
||||
use Symfony\Component\Security\Csrf\CsrfTokenManagerInterface;
|
||||
|
||||
@@ -76,6 +77,21 @@ class SecurityControllerTest extends ControllerBaseTest
|
||||
$this->assertTrue($client->getResponse()->isSuccessful());
|
||||
}
|
||||
|
||||
public function testLoginAlreadyLoggedIn()
|
||||
{
|
||||
$client = $this->getClientForAuthenticatedUser(User::ROLE_TEAMLEAD);
|
||||
|
||||
$this->request($client, '/login');
|
||||
|
||||
$this->assertIsRedirect($client, '/homepage'); // redirect to homepage
|
||||
$client->followRedirect();
|
||||
|
||||
$this->assertIsRedirect($client, '/timesheet/'); // redirect to configured start page
|
||||
$client->followRedirect();
|
||||
|
||||
$this->assertTrue($client->getResponse()->isSuccessful());
|
||||
}
|
||||
|
||||
public function testLoginNegative()
|
||||
{
|
||||
$client = self::createClient();
|
||||
|
||||
Reference in New Issue
Block a user