Issue #2635324 by dawehner: kernel tests are unrunnabble because markTestSkipped message is not displayed

8.1.x
Alex Pott 2015-12-16 11:25:51 +00:00
parent 25207d344b
commit d003c7276a
2 changed files with 2 additions and 2 deletions

View File

@ -291,7 +291,7 @@ abstract class BrowserTestBase extends \PHPUnit_Framework_TestCase {
// coverage against.
$base_url = getenv('SIMPLETEST_BASE_URL');
if (!$base_url) {
$this->markTestSkipped(
throw new \Exception(
'You must provide a SIMPLETEST_BASE_URL environment variable to run some PHPUnit based functional tests.'
);
}

View File

@ -406,7 +406,7 @@ abstract class KernelTestBase extends \PHPUnit_Framework_TestCase implements Ser
// If the test is run with argument dburl then use it.
$db_url = getenv('SIMPLETEST_DB');
if (empty($db_url)) {
$this->markTestSkipped('There is no database connection so no tests can be run. You must provide a SIMPLETEST_DB environment variable to run PHPUnit based functional tests outside of run-tests.sh. See https://www.drupal.org/node/2116263#skipped-tests for more information.');
throw new \Exception('There is no database connection so no tests can be run. You must provide a SIMPLETEST_DB environment variable to run PHPUnit based functional tests outside of run-tests.sh. See https://www.drupal.org/node/2116263#skipped-tests for more information.');
}
else {
$database = Database::convertDbUrlToConnectionInfo($db_url, $this->root);