public function ExpectDeprecationTest::testDeprecatedExpectDeprecation in Drupal 8
@covers ::expectDeprecation
@todo the expectedDeprecation annotation does not work if tests are marked skipped.
See also
https://github.com/symfony/symfony/pull/25757
File
- core/
tests/ Drupal/ Tests/ ExpectDeprecationTest.php, line 43
Class
- ExpectDeprecationTest
- @coversDefaultClass \Drupal\Tests\Traits\ExpectDeprecationTrait
Namespace
Drupal\TestsCode
public function testDeprecatedExpectDeprecation() {
$this
->addExpectedDeprecationMessage('ExpectDeprecationTrait::expectDeprecation is deprecated in drupal:8.8.5 and is removed from drupal:9.0.0. Use ::addExpectedDeprecationMessage() instead. See https://www.drupal.org/node/3106024');
$this
->expectDeprecation('Test deprecated expectDeprecation');
@trigger_error('Test deprecated expectDeprecation', E_USER_DEPRECATED);
}