diff --git a/core/modules/system/lib/Drupal/system/Tests/Installer/InstallerTranslationTest.php b/core/modules/system/lib/Drupal/system/Tests/Installer/InstallerTranslationTest.php index 69b3352..f2f879e 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Installer/InstallerTranslationTest.php +++ b/core/modules/system/lib/Drupal/system/Tests/Installer/InstallerTranslationTest.php @@ -8,6 +8,7 @@ namespace Drupal\system\Tests\Installer; use Drupal\Component\Utility\NestedArray; +use Drupal\simpletest\TestSetUpException; use Drupal\system\Tests\InstallerTest; /** @@ -43,9 +44,6 @@ protected function setUp() { // Prepare the environment for running tests. $this->prepareEnvironment(); - if (!$this->setupEnvironment) { - return FALSE; - } // Reset all statics and variables to perform tests in a clean environment. $conf = array(); @@ -57,8 +55,9 @@ protected function setUp() { // write back to persistent caches when they are destructed. $this->changeDatabasePrefix(); if (!$this->setupDatabasePrefix) { - return FALSE; + throw new TestSetUpException('The database prefix could not be changed for the test site.'); } + $variable_groups = array( 'system.file' => array( 'path.private' => $this->private_files_directory, diff --git a/core/modules/system/lib/Drupal/system/Tests/InstallerTest.php b/core/modules/system/lib/Drupal/system/Tests/InstallerTest.php index 5bbaab8..f068125 100644 --- a/core/modules/system/lib/Drupal/system/Tests/InstallerTest.php +++ b/core/modules/system/lib/Drupal/system/Tests/InstallerTest.php @@ -8,6 +8,7 @@ namespace Drupal\system\Tests; use Drupal\Component\Utility\NestedArray; +use Drupal\simpletest\TestSetUpException; use Drupal\simpletest\WebTestBase; /** @@ -38,9 +39,6 @@ protected function setUp() { // Prepare the environment for running tests. $this->prepareEnvironment(); - if (!$this->setupEnvironment) { - return FALSE; - } // Reset all statics and variables to perform tests in a clean environment. $conf = array(); @@ -52,7 +50,7 @@ protected function setUp() { // write back to persistent caches when they are destructed. $this->changeDatabasePrefix(); if (!$this->setupDatabasePrefix) { - return FALSE; + throw new TestSetUpException('The database prefix could not be changed for the test site.'); } $variable_groups = array( 'system.file' => array(