function SettingsTrayTestBase::getBlockSelector

Same name in other branches
  1. 8.9.x core/modules/settings_tray/tests/src/FunctionalJavascript/SettingsTrayTestBase.php \Drupal\Tests\settings_tray\FunctionalJavascript\SettingsTrayTestBase::getBlockSelector()
  2. 10 core/modules/settings_tray/tests/src/FunctionalJavascript/SettingsTrayTestBase.php \Drupal\Tests\settings_tray\FunctionalJavascript\SettingsTrayTestBase::getBlockSelector()
  3. 11.x core/modules/settings_tray/tests/src/FunctionalJavascript/SettingsTrayTestBase.php \Drupal\Tests\settings_tray\FunctionalJavascript\SettingsTrayTestBase::getBlockSelector()

Gets the block CSS selector.

Parameters

\Drupal\block\Entity\Block $block: The block.

Return value

string The CSS selector.

8 calls to SettingsTrayTestBase::getBlockSelector()
ConfigAccessTest::testBlockConfigAccess in core/modules/settings_tray/tests/src/FunctionalJavascript/ConfigAccessTest.php
Tests access to block forms with related configuration is correct.
OverriddenConfigurationTest::assertOverriddenBlockDisabled in core/modules/settings_tray/tests/src/FunctionalJavascript/OverriddenConfigurationTest.php
Asserts that an overridden block has Settings Tray disabled.
OverriddenConfigurationTest::testOverriddenBlock in core/modules/settings_tray/tests/src/FunctionalJavascript/OverriddenConfigurationTest.php
Tests that blocks with configuration overrides are disabled.
OverriddenConfigurationTest::testOverriddenConfigurationRemoved in core/modules/settings_tray/tests/src/FunctionalJavascript/OverriddenConfigurationTest.php
Tests blocks with overridden related configuration removed when overridden.
SettingsTrayBlockFormTest::doTestBlocks in core/modules/settings_tray/tests/src/FunctionalJavascript/SettingsTrayBlockFormTest.php
Tests opening off-canvas dialog by click blocks and elements in the blocks.

... See full list

File

core/modules/settings_tray/tests/src/FunctionalJavascript/SettingsTrayTestBase.php, line 175

Class

SettingsTrayTestBase
Base class for Settings Tray tests.

Namespace

Drupal\Tests\settings_tray\FunctionalJavascript

Code

public function getBlockSelector(Block $block) {
    return '#block-' . str_replace('_', '-', $block->id());
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.