You are here

protected function ResourceTestBase::getAuthenticationRequestOptions in Drupal 10

Same name in this branch
  1. 10 core/modules/jsonapi/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\jsonapi\Functional\ResourceTestBase::getAuthenticationRequestOptions()
  2. 10 core/modules/rest/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\rest\Functional\ResourceTestBase::getAuthenticationRequestOptions()
Same name and namespace in other branches
  1. 8 core/modules/rest/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\rest\Functional\ResourceTestBase::getAuthenticationRequestOptions()
  2. 9 core/modules/rest/tests/src/Functional/ResourceTestBase.php \Drupal\Tests\rest\Functional\ResourceTestBase::getAuthenticationRequestOptions()

Returns Guzzle request options for authentication.

Parameters

string $method: The HTTP method for this authenticated request.

Return value

array Guzzle request options to use for authentication.

See also

\GuzzleHttp\ClientInterface::request()

7 calls to ResourceTestBase::getAuthenticationRequestOptions()
EntityResourceTestBase::testDelete in core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php
Tests a DELETE request for an entity, plus edge cases to ensure good DX.
EntityResourceTestBase::testGet in core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php
Tests a GET request for an entity, plus edge cases to ensure good DX.
EntityResourceTestBase::testPatch in core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php
Tests a PATCH request for an entity, plus edge cases to ensure good DX.
EntityResourceTestBase::testPost in core/modules/rest/tests/src/Functional/EntityResource/EntityResourceTestBase.php
Tests a POST request for an entity, plus edge cases to ensure good DX.
MediaResourceTestBase::uploadFile in core/modules/media/tests/src/Functional/Rest/MediaResourceTestBase.php
This duplicates some of the 'file_upload' REST resource plugin test coverage, to be able to test it on a concrete use case.

... See full list

File

core/modules/rest/tests/src/Functional/ResourceTestBase.php, line 284

Class

ResourceTestBase
Subclass this for every REST resource, every format and every auth provider.

Namespace

Drupal\Tests\rest\Functional

Code

protected function getAuthenticationRequestOptions($method) {
  return [];
}