function ResourceTestBase::setUpRevisionAuthorization
Same name in other branches
- 9 core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::setUpRevisionAuthorization()
- 8.9.x core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::setUpRevisionAuthorization()
- 10 core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::setUpRevisionAuthorization()
Sets up the necessary authorization for handling revisions.
Parameters
string $method: The HTTP method for which to set up authentication.
See also
::testRevisions()
5 calls to ResourceTestBase::setUpRevisionAuthorization()
- BlockContentTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ BlockContentTest.php - MediaTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ MediaTest.php - NodeTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ NodeTest.php - ResourceTestBase::testRevisions in core/
modules/ jsonapi/ tests/ src/ Functional/ ResourceTestBase.php - Tests individual and collection revisions.
- TermTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ TermTest.php
4 methods override ResourceTestBase::setUpRevisionAuthorization()
- BlockContentTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ BlockContentTest.php - MediaTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ MediaTest.php - NodeTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ NodeTest.php - TermTest::setUpRevisionAuthorization in core/
modules/ jsonapi/ tests/ src/ Functional/ TermTest.php
File
-
core/
modules/ jsonapi/ tests/ src/ Functional/ ResourceTestBase.php, line 631
Class
- ResourceTestBase
- Subclass this for every JSON:API resource type.
Namespace
Drupal\Tests\jsonapi\FunctionalCode
protected function setUpRevisionAuthorization($method) {
assert($method === 'GET', 'Only read operations on revisions are supported.');
$this->setUpAuthorization($method);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.