X-Git-Url: http://aleph1.co.uk/gitweb/?a=blobdiff_plain;f=web%2Fcore%2Fmodules%2Fsimpletest%2Fsrc%2FTests%2FInstallationProfileModuleTestsTest.php;h=113748f18d5ec2bb0c4fedb337c83cceebb2b29f;hb=1c1cb0980bfa6caf0c24cce671b6bb541dc87583;hp=379aed4499026af41190d6bea62e6d9933ab1148;hpb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;p=yaffs-website diff --git a/web/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php b/web/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php index 379aed449..113748f18 100644 --- a/web/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php +++ b/web/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php @@ -19,7 +19,7 @@ class InstallationProfileModuleTestsTest extends WebTestBase { public static $modules = ['simpletest']; /** - * An administrative user with permission to adminsiter unit tests. + * An administrative user with permission to administer unit tests. * * @var \Drupal\user\UserInterface */ @@ -35,7 +35,9 @@ class InstallationProfileModuleTestsTest extends WebTestBase { * - but still install the drupal_system_listing_compatible_test.module * contained in the Testing profile. * - * @see \Drupal\drupal_system_listing_compatible_test\Tests\SystemListingCompatibleTest + * @see \Drupal\Tests\drupal_system_listing_compatible_test\Kernel\SystemListingCrossProfileCompatibleTest + * + * @var string */ protected $profile = 'testing'; @@ -51,12 +53,18 @@ class InstallationProfileModuleTestsTest extends WebTestBase { */ public function testInstallationProfileTests() { $this->drupalGet('admin/config/development/testing'); - $this->assertText('Drupal\drupal_system_listing_compatible_test\Tests\SystemListingCompatibleTest'); + $this->assertText('Drupal\Tests\drupal_system_listing_compatible_test\Kernel\SystemListingCrossProfileCompatibleTest'); $edit = [ - 'tests[Drupal\drupal_system_listing_compatible_test\Tests\SystemListingCompatibleTest]' => TRUE, + 'tests[Drupal\Tests\drupal_system_listing_compatible_test\Kernel\SystemListingCrossProfileCompatibleTest]' => TRUE, ]; $this->drupalPostForm(NULL, $edit, t('Run tests')); - $this->assertText('SystemListingCompatibleTest test executed.'); + + // Verifies that tests in installation profile modules are passed. + $element = $this->xpath('//tr[contains(@class, :class)]/td[contains(text(), :value)]', [ + ':class' => 'simpletest-pass', + ':value' => 'Drupal\Tests\drupal_system_listing_compatible_test\Kernel\SystemListingCrossProfileCompatibleTest', + ]); + $this->assertTrue(!empty($element)); } }