protected function SimpletestPhpunitRunCommandTest::setUp in Drupal 8
File
- core/
modules/ simpletest/ tests/ src/ Unit/ SimpletestPhpunitRunCommandTest.php, line 66
Class
- SimpletestPhpunitRunCommandTest
- Tests simpletest_run_phpunit_tests() handles PHPunit fatals correctly.
Namespace
Drupal\Tests\simpletest\UnitCode
protected function setUp() {
parent::setUp();
// Organize our mock container.
$container = new ContainerBuilder();
$container
->set('app.root', self::$root);
$file_system = $this
->prophesize(FileSystemInterface::class);
// The simpletest directory wrapper will always point to /tmp.
$file_system
->realpath('public://simpletest')
->willReturn(sys_get_temp_dir());
$container
->set('file_system', $file_system
->reveal());
\Drupal::setContainer($container);
$this->fixtureContainer = $container;
}