3 namespace Drupal\Tests\config_test\Functional\Rest;
5 use Drupal\config_test\Entity\ConfigTest;
6 use Drupal\Tests\rest\Functional\EntityResource\EntityResourceTestBase;
8 abstract class ConfigTestResourceTestBase extends EntityResourceTestBase {
13 public static $modules = ['config_test', 'config_test_rest'];
18 protected static $entityTypeId = 'config_test';
21 * @var \Drupal\config_test\ConfigTestInterface
28 protected function setUpAuthorization($method) {
29 $this->grantPermissionsToTestedRole(['view config_test']);
35 protected function createEntity() {
36 $config_test = ConfigTest::create([
48 protected function getExpectedNormalizedEntity() {
50 'uuid' => $this->entity->uuid(),
60 'protected_property' => NULL,
63 return $normalization;
69 protected function getNormalizedPostEntity() {
70 // @todo Update in https://www.drupal.org/node/2300677.