function MediaLibraryTestBase::switchToMediaLibraryTable
Same name in other branches
- 9 core/modules/media_library/tests/src/FunctionalJavascript/MediaLibraryTestBase.php \Drupal\Tests\media_library\FunctionalJavascript\MediaLibraryTestBase::switchToMediaLibraryTable()
- 8.9.x core/modules/media_library/tests/src/FunctionalJavascript/MediaLibraryTestBase.php \Drupal\Tests\media_library\FunctionalJavascript\MediaLibraryTestBase::switchToMediaLibraryTable()
- 11.x core/modules/media_library/tests/src/FunctionalJavascript/MediaLibraryTestBase.php \Drupal\Tests\media_library\FunctionalJavascript\MediaLibraryTestBase::switchToMediaLibraryTable()
Switches to the table display of the widget view.
1 call to MediaLibraryTestBase::switchToMediaLibraryTable()
- WidgetViewsTest::testWidgetViews in core/
modules/ media_library/ tests/ src/ FunctionalJavascript/ WidgetViewsTest.php - Tests that the views in the Media library's widget work as expected.
File
-
core/
modules/ media_library/ tests/ src/ FunctionalJavascript/ MediaLibraryTestBase.php, line 435
Class
- MediaLibraryTestBase
- Base class for functional tests of Media Library functionality.
Namespace
Drupal\Tests\media_library\FunctionalJavascriptCode
protected function switchToMediaLibraryTable() {
hold_test_response(TRUE);
$this->getSession()
->getPage()
->clickLink('Table');
// Assert the display change is correctly announced for screen readers.
$this->assertAnnounceContains('Loading table view.');
hold_test_response(FALSE);
$this->assertAnnounceContains('Changed to table view.');
$this->assertMediaLibraryTable();
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.