You are here

final class ViewsContext in Lightning Core 8.3

Same name and namespace in other branches
  1. 8.5 tests/contexts/ViewsContext.behat.inc \Acquia\LightningExtension\Context\ViewsContext
  2. 8 tests/contexts/ViewsContext.behat.inc \Acquia\LightningExtension\Context\ViewsContext
  3. 8.2 tests/contexts/ViewsContext.behat.inc \Acquia\LightningExtension\Context\ViewsContext
  4. 8.4 tests/contexts/ViewsContext.behat.inc \Acquia\LightningExtension\Context\ViewsContext

Contains step definitions for working with views.

@internal This is an internal part of Lightning Core's testing system and may be changed or removed at any time without warning. It should not be extended, instantiated, or used in any way by external code! If you need to use this functionality, you should copy the relevant code into your own project.

Hierarchy

  • class \Acquia\LightningExtension\Context\ViewsContext extends \Drupal\DrupalExtension\Context\DrupalSubContextBase uses AwaitTrait

Expanded class hierarchy of ViewsContext

File

tests/contexts/ViewsContext.behat.inc, line 16

Namespace

Acquia\LightningExtension\Context
View source
final class ViewsContext extends DrupalSubContextBase {
  use AwaitTrait;

  /**
   * Submits exposed Views filters.
   *
   * @When I apply the exposed filters
   */
  public function applyExposedFilters() {
    $this
      ->assertSession()
      ->elementExists('css', '.views-exposed-form .form-actions input[type = "submit"]')
      ->press();
    $this
      ->awaitAjax();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
AwaitTrait::awaitAjax protected function Waits for AJAX to finish.
AwaitTrait::awaitElement protected function Waits for an element to exist.
AwaitTrait::awaitExpression protected function Waits for a JavaScript condition to become true.
ViewsContext::applyExposedFilters public function Submits exposed Views filters.