Skip to content

Commit f7b5f27

Browse files
mnoconOstafinL
authored andcommitted
[Behat] Adapted tests
1 parent 56d3321 commit f7b5f27

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/lib/Behat/Component/UpperMenu.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public function setFocusMode(bool $expectedModeStatus): void
5151
$isEnabled = $this->getHTMLPage()->setTimeout(3)->findAll($this->getLocator('userFocusEnabled'))->any();
5252

5353
if ($expectedModeStatus != $isEnabled) {
54-
$this->getHTMLPage()->find($this->getLocator('focusMode'))->click();
54+
$this->getHTMLPage()->find($this->getLocator('userFocusMode'))->click();
5555

5656
return;
5757
}
@@ -75,7 +75,7 @@ protected function specifyLocators(): array
7575
new VisibleCSSLocator('userSettingsPopup', '.ibexa-header-user-menu .ibexa-header-user-menu__popup-menu'),
7676
new VisibleCSSLocator('searchInput', '.ibexa-main-header #search_query'),
7777
new VisibleCSSLocator('searchButton', '.ibexa-main-header .ibexa-input-text-wrapper__action-btn--search'),
78-
new VisibleCSSLocator('userFocusEnabled', '#focus_mode_change_enabled'),
78+
new VisibleCSSLocator('userFocusEnabled', '[name="focus_mode_change"] .ibexa-toggle__label--on'),
7979
new VisibleCSSLocator('userFocusMode', '[name="focus_mode_change"] .ibexa-toggle__switcher'),
8080
];
8181
}

src/lib/Behat/Page/ContentViewPage.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,8 @@ public function setFocusMode(bool $expectedModeStatus): void
186186
{
187187
$this->upperMenu->setFocusMode($expectedModeStatus);
188188

189-
$focusModeExcludedTab = 'Versions';
189+
// TODO: Rework this after Focus mode label is visible next to Ibexa's logo
190+
$focusModeExcludedTab = 'Technical Details';
190191

191192
if ($expectedModeStatus) {
192193
$this->getHTMLPage()

0 commit comments

Comments
 (0)