You are here

public function DurationFieldBrowserTestBase::assertElementAttributeExists in Duration Field 3.0.x

Same name and namespace in other branches
  1. 8.2 tests/src/Functional/DurationFieldBrowserTestBase.php \Drupal\Tests\duration_field\Functional\DurationFieldBrowserTestBase::assertElementAttributeExists()
  2. 8 tests/src/Functional/DurationFieldBrowserTestBase.php \Drupal\Tests\duration_field\Functional\DurationFieldBrowserTestBase::assertElementAttributeExists()

Asserts that an attribute exists on an element.

File

tests/src/Functional/DurationFieldBrowserTestBase.php, line 29

Class

DurationFieldBrowserTestBase
Base class that provides some helper functions for functional tests.

Namespace

Drupal\Tests\duration_field\Functional

Code

public function assertElementAttributeExists($selector, $attribute) {
  $this
    ->assertSession()
    ->elementAttributeExists('css', $selector, $attribute);
}