File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
src/main/java/qa/autotest/framework/pages Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 55import io .qameta .allure .Step ;
66import lombok .extern .slf4j .Slf4j ;
77
8- import java .time .Duration ;
98
109import static com .codeborne .selenide .Selenide .$ ;
1110
@@ -95,16 +94,19 @@ public BasePage openBurgerMenu() {
9594 /**
9695 * Closes the burger menu.
9796 *
98- * <p>Precondition: the menu must be open. If it is not, Selenide will throw
97+ * <p>Precondition: the menu must be open. Uses global {@code Configuration.timeout}
98+ * (default: 10 s) — tolerates slow CSS animations in headless CI.
99+ *
100+ * <p>If it is not open, Selenide will throw
99101 * a timeout exception — this is intentional (fail-fast on wrong test state).
100102 *
101103 * @return current page instance
102104 */
103105 @ Step ("Close burger menu" )
104106 public BasePage closeBurgerMenu () {
105107 log .info ("Closing burger menu" );
106- closeMenuButton ().click ();
107- sidebarMenu ().shouldNotBe (Condition .visible , Duration . ofSeconds ( 3 ) );
108+ closeMenuButton ().shouldBe ( Condition . visible ). click ();
109+ sidebarMenu ().shouldNotBe (Condition .visible );
108110 return this ;
109111 }
110112
You can’t perform that action at this time.
0 commit comments