diff --git a/core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php b/core/tests/Drupal/Tests/Core/Scripts/TestSiteApplicationTest.php similarity index 97% rename from core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php rename to core/tests/Drupal/Tests/Core/Scripts/TestSiteApplicationTest.php index c8d5b81173..7b6d08ea2a 100644 --- a/core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php +++ b/core/tests/Drupal/Tests/Core/Scripts/TestSiteApplicationTest.php @@ -1,6 +1,6 @@ root = dirname(dirname(substr(__DIR__, 0, -strlen(__NAMESPACE__)))); - } + } /** * Gets the connection object for the specified database key and target. @@ -113,7 +116,7 @@ public function testInstallWithNonSetupClass() { $process = new Process($command_line, $this->root, ['COLUMNS' => PHP_INT_MAX]); $process->run(); - $this->assertContains('The class Drupal\Tests\Scripts\TestSiteApplicationTest contained in', $process->getErrorOutput()); + $this->assertContains('The class Drupal\Tests\Core\Scripts\TestSiteApplicationTest contained in', $process->getErrorOutput()); $this->assertContains('needs to implement \Drupal\TestSite\TestSetupInterface', $process->getErrorOutput()); $this->assertSame(1, $process->getExitCode()); $this->assertCount($table_count, $connection->schema()->findTables('%'), 'No additional tables created in the database'); @@ -295,7 +298,8 @@ public function testTearDownDbPrefixValidation() { * The database key of the added connection. */ protected function addTestDatabase($db_prefix) { - if (getenv('SIMPLETEST_DB') === FALSE) { + // If SIMPLETEST_DB is not set, it will be FALSE. It could also be empty. + if (empty(getenv('SIMPLETEST_DB'))) { $this->markTestSkipped('Needs the SIMPLETEST_DB environmental variable in order to install to a database.'); } $database = Database::convertDbUrlToConnectionInfo(getenv('SIMPLETEST_DB'), $this->root);