You are here

protected function TestBase::assertNoXpath in Double Field 4.x

Same name in this branch
  1. 4.x tests/src/Functional/TestBase.php \Drupal\Tests\double_field\Functional\TestBase::assertNoXpath()
  2. 4.x tests/src/FunctionalJavascript/TestBase.php \Drupal\Tests\double_field\FunctionalJavascript\TestBase::assertNoXpath()
Same name and namespace in other branches
  1. 8.3 tests/src/Functional/TestBase.php \Drupal\Tests\double_field\Functional\TestBase::assertNoXpath()

Checks that an element does not exist on the current page.

Parameters

string|array $xpath: The XPath identifying the element to check.

2 calls to TestBase::assertNoXpath()
DateTimezoneTest::testDateSubfield in tests/src/Functional/DateTimezoneTest.php
Test callback.
FieldTypeTest::testFieldSettingsForm in tests/src/Functional/FieldTypeTest.php
Test field settings form.

File

tests/src/Functional/TestBase.php, line 227

Class

TestBase
Tests the creation of text fields.

Namespace

Drupal\Tests\double_field\Functional

Code

protected function assertNoXpath($xpath) : void {
  if (is_array($xpath)) {
    $xpath = implode($xpath);
  }
  $this
    ->assertSession()
    ->elementNotExists('xpath', $xpath);
}