public function BrowserTestBaseTest::testAssertPattern in Drupal 9
Tests legacy assertPattern().
@group legacy
File
- core/
tests/ Drupal/ FunctionalTests/ BrowserTestBaseTest.php, line 311
Class
- BrowserTestBaseTest
- Tests BrowserTestBase functionality.
Namespace
Drupal\FunctionalTestsCode
public function testAssertPattern() {
$this
->expectDeprecation('AssertLegacyTrait::assertPattern() is deprecated in drupal:8.2.0 and is removed from drupal:10.0.0. Use $this->assertSession()->responseMatches() instead. See https://www.drupal.org/node/3129738');
$this
->drupalGet('test-escaped-characters');
$this
->assertPattern('/div class.*escaped/');
}