function TestSiteApplicationTest::testTearDownDbPrefixValidation
Same name in this branch
- 11.x core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php \Drupal\Tests\Scripts\TestSiteApplicationTest::testTearDownDbPrefixValidation()
Same name in other branches
- 9 core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php \Drupal\Tests\Scripts\TestSiteApplicationTest::testTearDownDbPrefixValidation()
- 8.9.x core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php \Drupal\Tests\Scripts\TestSiteApplicationTest::testTearDownDbPrefixValidation()
- 10 core/tests/Drupal/Tests/Scripts/TestSiteApplicationTest.php \Drupal\Tests\Scripts\TestSiteApplicationTest::testTearDownDbPrefixValidation()
@coversNothing
File
-
core/
tests/ Drupal/ KernelTests/ Scripts/ TestSiteApplicationTest.php, line 222
Class
- TestSiteApplicationTest
- Tests core/scripts/test-site.php.
Namespace
Drupal\KernelTests\ScriptsCode
public function testTearDownDbPrefixValidation() : void {
$command_line = $this->php . ' core/scripts/test-site.php tear-down not-a-valid-prefix';
$process = Process::fromShellCommandline($command_line, $this->root);
$process->setTimeout(500);
$process->run();
$this->assertSame(1, $process->getExitCode());
$this->assertStringContainsString('Invalid database prefix: not-a-valid-prefix', $process->getErrorOutput());
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.