Follow-up to #2262147: Various base test classes are not abstract

Various migrate_drupal PHPUnit base test classes are declared wrongly, because:

  1. The base test classes are not declared as abstract.
  2. The base test classes wrongly implement getInfo().
  3. The root test class MigrateSqlSourceTestCase implements a test*() method, which turns the base classes into valid test classes.

Due to all issues combined, the error is not and cannot be caught by any of the existing test class validations.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

sun’s picture

Issue summary: View changes
sun’s picture

Issue tags: +Quick fix
ParisLiakos’s picture

Status: Needs review » Reviewed & tested by the community
chx’s picture

Status: Reviewed & tested by the community » Needs work
+ * Base class for taxnomony term source unit tests

+ * Base class for taxomony term source unit tests

sun’s picture

Status: Needs work » Reviewed & tested by the community
FileSize
6.45 KB

Whoops, thanks.

benjy’s picture

This looks good to me. +1 for RTBC

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed ac7e61e and pushed to 8.x. Thanks!

diff -u b/core/modules/migrate_drupal/tests/src/source/d6/TermTestBase.php b/core/modules/migrate_drupal/tests/src/source/d6/TermTestBase.php
--- b/core/modules/migrate_drupal/tests/src/source/d6/TermTestBase.php
+++ b/core/modules/migrate_drupal/tests/src/source/d6/TermTestBase.php
@@ -10,7 +10,7 @@
 use Drupal\migrate\Tests\MigrateSqlSourceTestCase;

 /**
- * Base class for taxnomony term source unit tests.
+ * Base class for taxonomy term source unit tests.
  */
 abstract class TermTestBase extends MigrateSqlSourceTestCase {

Interdiff between #0 and #5

  • alexpott committed ac7e61e on 8.x
    Issue #2293807 by sun: Fixed Various migrate_drupal unit base test...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.