function AnonResourceTestTrait::assertResponseWhenMissingAuthentication
Same name in other branches
- 9 core/modules/rest/tests/src/Functional/AnonResourceTestTrait.php \Drupal\Tests\rest\Functional\AnonResourceTestTrait::assertResponseWhenMissingAuthentication()
- 8.9.x core/modules/rest/tests/src/Functional/AnonResourceTestTrait.php \Drupal\Tests\rest\Functional\AnonResourceTestTrait::assertResponseWhenMissingAuthentication()
- 10 core/modules/rest/tests/src/Functional/AnonResourceTestTrait.php \Drupal\Tests\rest\Functional\AnonResourceTestTrait::assertResponseWhenMissingAuthentication()
File
-
core/
modules/ rest/ tests/ src/ Functional/ AnonResourceTestTrait.php, line 32
Class
- AnonResourceTestTrait
- Defines a trait for testing with no authentication provider.
Namespace
Drupal\Tests\rest\FunctionalCode
protected function assertResponseWhenMissingAuthentication($method, ResponseInterface $response) {
throw new \LogicException('When testing for anonymous users, authentication cannot be missing.');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.