ConfigEntityResourceTestBase.php

Same filename in this branch
  1. 11.x core/modules/jsonapi/tests/src/Functional/ConfigEntityResourceTestBase.php
Same filename and directory in other branches
  1. 9 core/modules/jsonapi/tests/src/Functional/ConfigEntityResourceTestBase.php
  2. 9 core/modules/rest/tests/src/Functional/EntityResource/ConfigEntityResourceTestBase.php
  3. 10 core/modules/jsonapi/tests/src/Functional/ConfigEntityResourceTestBase.php
  4. 10 core/modules/rest/tests/src/Functional/EntityResource/ConfigEntityResourceTestBase.php

Namespace

Drupal\Tests\rest\Functional\EntityResource

File

core/modules/rest/tests/src/Functional/EntityResource/ConfigEntityResourceTestBase.php

View source
<?php

declare (strict_types=1);
namespace Drupal\Tests\rest\Functional\EntityResource;


/**
 * Resource test base class for config entities.
 *
 * @todo Remove this in https://www.drupal.org/node/2300677.
 */
abstract class ConfigEntityResourceTestBase extends EntityResourceTestBase {
    
    /**
     * A list of test methods to skip.
     *
     * @var array
     */
    const SKIP_METHODS = [
        'testPost',
        'testPatch',
        'testDelete',
    ];
    
    /**
     * {@inheritdoc}
     */
    protected function setUp() : void {
        if (in_array($this->name(), static::SKIP_METHODS, TRUE)) {
            // Skip before installing Drupal to prevent unnecessary use of resources.
            $this->markTestSkipped("Not yet supported for config entities.");
        }
        parent::setUp();
    }

}

Classes

Title Deprecated Summary
ConfigEntityResourceTestBase Resource test base class for config entities.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.