function AuthenticationManagerTest::testApplyFilterWithFilterprovider
Same name in other branches
- 9 core/tests/Drupal/Tests/Core/Authentication/AuthenticationManagerTest.php \Drupal\Tests\Core\Authentication\AuthenticationManagerTest::testApplyFilterWithFilterProvider()
- 10 core/tests/Drupal/Tests/Core/Authentication/AuthenticationManagerTest.php \Drupal\Tests\Core\Authentication\AuthenticationManagerTest::testApplyFilterWithFilterProvider()
- 11.x core/tests/Drupal/Tests/Core/Authentication/AuthenticationManagerTest.php \Drupal\Tests\Core\Authentication\AuthenticationManagerTest::testApplyFilterWithFilterProvider()
@covers ::applyFilter
File
-
core/
tests/ Drupal/ Tests/ Core/ Authentication/ AuthenticationManagerTest.php, line 52
Class
- AuthenticationManagerTest
- @coversDefaultClass \Drupal\Core\Authentication\AuthenticationManager @group Authentication
Namespace
Drupal\Tests\Core\AuthenticationCode
public function testApplyFilterWithFilterprovider() {
$auth_provider = $this->createMock('Drupal\\Tests\\Core\\Authentication\\TestAuthenticationProviderInterface');
$auth_provider->expects($this->once())
->method('appliesToRoutedRequest')
->willReturn(TRUE);
$authentication_collector = new AuthenticationCollector();
$authentication_collector->addProvider($auth_provider, 'filtered', 0);
$authentication_manager = new AuthenticationManager($authentication_collector);
$request = new Request();
$this->assertTrue($authentication_manager->appliesToRoutedRequest($request, FALSE));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.