You are here

protected function WebformAssertLegacyTrait::assertNoField in Webform 6.x

Same name and namespace in other branches
  1. 8.5 tests/src/Traits/WebformAssertLegacyTrait.php \Drupal\Tests\webform\Traits\WebformAssertLegacyTrait::assertNoField()

Asserts that a field does NOT exist with the given name or ID.

Parameters

string $field: Name or ID of field to assert.

File

tests/src/Traits/WebformAssertLegacyTrait.php, line 295

Class

WebformAssertLegacyTrait
Provides convenience methods for assertions in browser tests.

Namespace

Drupal\Tests\webform\Traits

Code

protected function assertNoField($field) {
  $this
    ->assertNoFieldByXPath($this
    ->constructFieldXpath('name', $field) . '|' . $this
    ->constructFieldXpath('id', $field));
}