public function ScaffoldTest::testScaffoldWithExpectedException in Drupal 10
Same name and namespace in other branches
- 8 core/tests/Drupal/Tests/Composer/Plugin/Scaffold/Functional/ScaffoldTest.php \Drupal\Tests\Composer\Plugin\Scaffold\Functional\ScaffoldTest::testScaffoldWithExpectedException()
- 9 core/tests/Drupal/Tests/Composer/Plugin/Scaffold/Functional/ScaffoldTest.php \Drupal\Tests\Composer\Plugin\Scaffold\Functional\ScaffoldTest::testScaffoldWithExpectedException()
Tests that scaffold files throw when they have bad values.
@dataProvider scaffoldExpectedExceptionTestValues
Parameters
string $fixture_name: The name of the fixture to use from core/tests/Drupal/Tests/Component/Scaffold/fixtures.
string $expected_exception_message: The expected exception message.
bool $is_link: Whether or not symlinking should be used.
File
- core/
tests/ Drupal/ Tests/ Composer/ Plugin/ Scaffold/ Functional/ ScaffoldTest.php, line 171
Class
- ScaffoldTest
- Tests Composer Scaffold.
Namespace
Drupal\Tests\Composer\Plugin\Scaffold\FunctionalCode
public function testScaffoldWithExpectedException($fixture_name, $expected_exception_message, $is_link) {
// Test scaffold. Expect an error.
$this
->expectException(\Exception::class);
$this
->expectExceptionMessage($expected_exception_message);
$this
->scaffoldSut($fixture_name, $is_link);
}