mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 18:03:17 +00:00
20 lines
532 B
PHP
20 lines
532 B
PHP
<?php
|
|
|
|
namespace Alchemy\Tests\Phrasea\Security;
|
|
|
|
class FirewallTest extends \PhraseanetWebTestCaseAuthenticatedAbstract
|
|
{
|
|
protected $client;
|
|
|
|
public function testRequiredAuth()
|
|
{
|
|
$this->assertNull(self::$DI['app']['firewall']->requireAuthentication());
|
|
}
|
|
|
|
public function testRequiredAuthNotAuthenticated()
|
|
{
|
|
$this->logout(self::$DI['app']);
|
|
$this->assertInstanceOf('Symfony\Component\HttpFoundation\RedirectResponse', self::$DI['app']['firewall']->requireAuthentication());
|
|
}
|
|
}
|