protected function ThunderJavascriptTestBase::assertPageTitle in Thunder 6.2.x
Same name and namespace in other branches
- 8.5 tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php \Drupal\Tests\thunder\FunctionalJavascript\ThunderJavascriptTestBase::assertPageTitle()
- 8.2 tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php \Drupal\Tests\thunder\FunctionalJavascript\ThunderJavascriptTestBase::assertPageTitle()
- 8.3 tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php \Drupal\Tests\thunder\FunctionalJavascript\ThunderJavascriptTestBase::assertPageTitle()
- 8.4 tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php \Drupal\Tests\thunder\FunctionalJavascript\ThunderJavascriptTestBase::assertPageTitle()
- 6.0.x tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php \Drupal\Tests\thunder\FunctionalJavascript\ThunderJavascriptTestBase::assertPageTitle()
- 6.1.x tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php \Drupal\Tests\thunder\FunctionalJavascript\ThunderJavascriptTestBase::assertPageTitle()
Assert page title.
Parameters
string $expectedTitle: Expected title.
3 calls to ThunderJavascriptTestBase::assertPageTitle()
- ArticleCreationTest::testCreateArticle in tests/
src/ FunctionalJavascript/ ArticleCreationTest.php - Test Creation of Article.
- ArticleCreationTest::testCreateArticleWithNoModeration in tests/
src/ FunctionalJavascript/ ArticleCreationTest.php - Test Creation of Article without content moderation.
- ArticleCreationTest::testModerationWorkflow in tests/
src/ FunctionalJavascript/ ArticleCreationTest.php - Tests draft creation and that reverting to the default revision works.
File
- tests/
src/ FunctionalJavascript/ ThunderJavascriptTestBase.php, line 270
Class
- ThunderJavascriptTestBase
- Base class for Thunder Javascript functional tests.
Namespace
Drupal\Tests\thunder\FunctionalJavascriptCode
protected function assertPageTitle($expectedTitle) {
$driver = $this
->getSession()
->getDriver();
if ($driver instanceof Selenium2Driver) {
$actualTitle = $driver
->getWebDriverSession()
->title();
static::assertEquals($expectedTitle, $actualTitle, 'Title found');
}
else {
$this
->assertSession()
->titleEquals($expectedTitle);
}
}