assertMediaLibraryTable example

/** * Switches to the table display of the widget view. */
  protected function switchToMediaLibraryTable() {
    hold_test_response(TRUE);
    $this->getSession()->getPage()->clickLink('Table');
    // Assert the display change is correctly announced for screen readers.     $this->waitForText('Loading table view.');
    hold_test_response(FALSE);
    $this->waitForText('Changed to table view.');
    $this->assertMediaLibraryTable();
  }

  /** * Asserts that the grid display of the widget view is visible. */
  protected function assertMediaLibraryGrid() {
    $this->assertSession()->assertWaitOnAjaxRequest();
    $this->assertSession()
      ->elementExists('css', '.js-media-library-view[data-view-display-id="widget"]');
  }

  
Home | Imprint | This part of the site doesn't use cookies.