.../custom_block/Tests/CustomBlockCacheTagsTest.php | 2 +- .../lib/Drupal/comment/Tests/CommentCacheTagsTest.php | 2 +- .../node/lib/Drupal/node/Tests/NodeCacheTagsTest.php | 2 +- core/modules/simpletest/simpletest.module | 1 + .../system/Tests/Entity/EntityCacheTagsTestBase.php | 13 +++++-------- .../lib/Drupal/taxonomy/Tests/TermCacheTagsTest.php | 2 +- .../user/lib/Drupal/user/Tests/UserCacheTagsTest.php | 2 +- 7 files changed, 11 insertions(+), 13 deletions(-) diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockCacheTagsTest.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockCacheTagsTest.php index 9d2139a..6270631 100644 --- a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockCacheTagsTest.php +++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockCacheTagsTest.php @@ -23,7 +23,7 @@ class CustomBlockCacheTagsTest extends EntityCacheTagsTestBase { * {@inheritdoc} */ public static function getInfo() { - return static::generateStandardizedInfo('custom_block', 'Custom Block'); + return static::generateStandardizedInfo('Custom Block', 'Custom Block'); } /** diff --git a/core/modules/comment/lib/Drupal/comment/Tests/CommentCacheTagsTest.php b/core/modules/comment/lib/Drupal/comment/Tests/CommentCacheTagsTest.php index 4af30b1..d42ec20 100644 --- a/core/modules/comment/lib/Drupal/comment/Tests/CommentCacheTagsTest.php +++ b/core/modules/comment/lib/Drupal/comment/Tests/CommentCacheTagsTest.php @@ -23,7 +23,7 @@ class CommentCacheTagsTest extends EntityWithUriCacheTagsTestBase { * {@inheritdoc} */ public static function getInfo() { - return static::generateStandardizedInfo('comment', 'Comment'); + return static::generateStandardizedInfo('Comment', 'Comment'); } /** diff --git a/core/modules/node/lib/Drupal/node/Tests/NodeCacheTagsTest.php b/core/modules/node/lib/Drupal/node/Tests/NodeCacheTagsTest.php index 1ab13c7..b97e653 100644 --- a/core/modules/node/lib/Drupal/node/Tests/NodeCacheTagsTest.php +++ b/core/modules/node/lib/Drupal/node/Tests/NodeCacheTagsTest.php @@ -23,7 +23,7 @@ class NodeCacheTagsTest extends EntityWithUriCacheTagsTestBase { * {@inheritdoc} */ public static function getInfo() { - return static::generateStandardizedInfo('node', 'Node'); + return static::generateStandardizedInfo('Node', 'Node'); } /** diff --git a/core/modules/simpletest/simpletest.module b/core/modules/simpletest/simpletest.module index 3571da9..5eb06ab 100644 --- a/core/modules/simpletest/simpletest.module +++ b/core/modules/simpletest/simpletest.module @@ -492,6 +492,7 @@ function simpletest_test_get_all($module = NULL) { // in an array keyed with the group specified in the test information. $groups = array(); foreach ($classes as $class) { + xdebug_break(); // Test classes need to implement getInfo() to be valid. if (class_exists($class) && method_exists($class, 'getInfo')) { $reflectionClass = new ReflectionClass($class); diff --git a/core/modules/system/lib/Drupal/system/Tests/Entity/EntityCacheTagsTestBase.php b/core/modules/system/lib/Drupal/system/Tests/Entity/EntityCacheTagsTestBase.php index 8dc682b..c49b0f3 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Entity/EntityCacheTagsTestBase.php +++ b/core/modules/system/lib/Drupal/system/Tests/Entity/EntityCacheTagsTestBase.php @@ -70,8 +70,8 @@ public function setUp() { /** * Generates the standardized test info. * - * @param string $entity_type_id - * The entity type ID whose cache tags to test. + * @param string $entity_type_label + * The label of the entity type whose cache tags to test. * @param string $group * The test group. * @@ -79,13 +79,10 @@ public function setUp() { * * @see \Drupal\simpletest\TestBase::getInfo() */ - protected static function generateStandardizedInfo($entity_type_id, $group) { - $label = \Drupal::entityManager() - ->getDefinition($entity_type_id) - ->getLabel(); + protected static function generateStandardizedInfo($entity_type_label, $group) { return array( - 'name' => "$label entity cache tags", - 'description' => "Test the $label entity's cache tags.", + 'name' => "$entity_type_label entity cache tags", + 'description' => "Test the $entity_type_label entity's cache tags.", 'group' => $group, ); } diff --git a/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TermCacheTagsTest.php b/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TermCacheTagsTest.php index 627da44..6d7b649 100644 --- a/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TermCacheTagsTest.php +++ b/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TermCacheTagsTest.php @@ -23,7 +23,7 @@ class TermCacheTagsTest extends EntityWithUriCacheTagsTestBase { * {@inheritdoc} */ public static function getInfo() { - return static::generateStandardizedInfo('taxonomy_term', 'Taxonomy'); + return static::generateStandardizedInfo('Taxonomy term', 'Taxonomy'); } /** diff --git a/core/modules/user/lib/Drupal/user/Tests/UserCacheTagsTest.php b/core/modules/user/lib/Drupal/user/Tests/UserCacheTagsTest.php index d9e1c8f..8db5b7b 100644 --- a/core/modules/user/lib/Drupal/user/Tests/UserCacheTagsTest.php +++ b/core/modules/user/lib/Drupal/user/Tests/UserCacheTagsTest.php @@ -23,7 +23,7 @@ class UserCacheTagsTest extends EntityWithUriCacheTagsTestBase { * {@inheritdoc} */ public static function getInfo() { - return static::generateStandardizedInfo('user', 'User'); + return static::generateStandardizedInfo('User', 'User'); } /**