public function PhpUnitWarningsTest::testAddWarning in Drupal 9
Tests that selected PHPUnit warning is converted to deprecation.
File
- core/
tests/ Drupal/ Tests/ PhpUnitWarningsTest.php, line 16
Class
- PhpUnitWarningsTest
- @coversDefaultClass \Drupal\Tests\Traits\PhpUnitWarnings @group legacy
Namespace
Drupal\TestsCode
public function testAddWarning() {
$this
->expectDeprecation('Test warning for \\Drupal\\Tests\\PhpUnitWarningsTest::testAddWarning()');
$this
->addWarning('Test warning for \\Drupal\\Tests\\PhpUnitWarningsTest::testAddWarning()');
}