You are here

public function JSInteractionTest::testNotClickable in Drupal 10

Assert an exception is thrown when the blocker element is never removed.

File

core/tests/Drupal/FunctionalJavascriptTests/Tests/JSInteractionTest.php, line 30

Class

JSInteractionTest
Tests fault tolerant interactions.

Namespace

Drupal\FunctionalJavascriptTests\Tests

Code

public function testNotClickable() {
  $this
    ->expectException(Exception::class);
  $this
    ->drupalGet('/js_interaction_test');
  $this
    ->assertSession()
    ->elementExists('named', [
    'link',
    'Target link',
  ])
    ->click();
}