class CommentJsonAnonTest
Same name and namespace in other branches
- 11.x core/modules/comment/tests/src/Functional/Rest/CommentJsonAnonTest.php \Drupal\Tests\comment\Functional\Rest\CommentJsonAnonTest
@group rest
Hierarchy
- class \Drupal\Tests\BrowserTestBase uses \Drupal\Core\Test\FunctionalTestSetupTrait, \Drupal\Tests\UiHelperTrait, \Drupal\Core\Test\TestSetupTrait, \Drupal\Tests\block\Traits\BlockCreationTrait, \Drupal\FunctionalTests\AssertLegacyTrait, \Drupal\Tests\RandomGeneratorTrait, \Drupal\Tests\node\Traits\NodeCreationTrait, \Drupal\Tests\node\Traits\ContentTypeCreationTrait, \Drupal\Tests\ConfigTestTrait, \Drupal\Tests\TestRequirementsTrait, \Drupal\Tests\user\Traits\UserCreationTrait, \Drupal\Tests\XdebugRequestTrait, \Drupal\Tests\Traits\PhpUnitWarnings, \Drupal\Tests\PhpUnitCompatibilityTrait, \Symfony\Bridge\PhpUnit\ExpectDeprecationTrait, \Drupal\Tests\ExtensionListTestTrait implements \PHPUnit\Framework\TestCase
- class \Drupal\Tests\rest\Functional\ResourceTestBase implements \Drupal\Tests\BrowserTestBase
- class \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase implements \Drupal\Tests\rest\Functional\ResourceTestBase
- class \Drupal\Tests\comment\Functional\Rest\CommentResourceTestBase uses \Drupal\comment\Tests\CommentTestTrait implements \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase
- class \Drupal\Tests\comment\Functional\Rest\CommentJsonAnonTest uses \Drupal\Tests\rest\Functional\AnonResourceTestTrait implements \Drupal\Tests\comment\Functional\Rest\CommentResourceTestBase
- class \Drupal\Tests\comment\Functional\Rest\CommentResourceTestBase uses \Drupal\comment\Tests\CommentTestTrait implements \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase
- class \Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase implements \Drupal\Tests\rest\Functional\ResourceTestBase
- class \Drupal\Tests\rest\Functional\ResourceTestBase implements \Drupal\Tests\BrowserTestBase
Expanded class hierarchy of CommentJsonAnonTest
File
-
core/
modules/ comment/ tests/ src/ Functional/ Rest/ CommentJsonAnonTest.php, line 10
Namespace
Drupal\Tests\comment\Functional\RestView source
class CommentJsonAnonTest extends CommentResourceTestBase {
use AnonResourceTestTrait;
/**
* {@inheritdoc}
*/
protected static $format = 'json';
/**
* {@inheritdoc}
*/
protected static $mimeType = 'application/json';
/**
* {@inheritdoc}
*/
protected $defaultTheme = 'stark';
/**
* {@inheritdoc}
*
* Anonymous users cannot edit their own comments.
*
* @see \Drupal\comment\CommentAccessControlHandler::checkAccess
*
* Therefore we grant them the 'administer comments' permission for the
* purpose of this test.
*
* @see ::setUpAuthorization
*/
protected static $patchProtectedFieldNames = [
'pid' => NULL,
'entity_id' => NULL,
'changed' => NULL,
'thread' => NULL,
'entity_type' => NULL,
'field_name' => NULL,
];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.