From 4f7525fe3920b370ac319259c023bfcabd1eb572 Mon Sep 17 00:00:00 2001
From: Elena7788
Hello kitty:*
-
'''
+
+ '''
)
answer = element().is_displayed()
@@ -57,10 +58,11 @@ def test_search_is_postponed_until_actual_action_like_questioning_displayed(
def test_search_is_updated_on_next_actual_action_like_questioning_displayed(
session_browser,
):
- element = session_browser.element('#will-be-existing-element').element(
- '.will-exist-inner'
- )
+ element = session_browser.element(
+ '#will-be-existing-element'
+ ).element('.will-exist-inner')
page = GivenPage(session_browser.driver)
+
page.opened_with_body(
'''
@@ -68,6 +70,7 @@ def test_search_is_updated_on_next_actual_action_like_questioning_displayed(
'''
)
+
assert element().is_displayed() is True
page.load_body(
@@ -76,14 +79,17 @@ def test_search_is_updated_on_next_actual_action_like_questioning_displayed(
kitty:*
- '''
+
+ '''
)
new_answer = element().is_displayed()
assert new_answer is False
-def test_search_finds_exactly_inside_parent(session_browser):
+def test_search_finds_exactly_inside_parent(
+ session_browser,
+):
page = GivenPage(session_browser.driver)
page.opened_with_body(
'''
@@ -92,7 +98,8 @@ def test_search_finds_exactly_inside_parent(session_browser):
go to Heading 2
Heading 1
Heading 2
- /p>'''
+ /p>
+ '''
)
session_browser.element('p').element('a').click()
diff --git a/tests/integration/element__lazy_search_test.py b/tests/integration/element__lazy_search_test.py
index efdb42f2..74b39c7c 100644
--- a/tests/integration/element__lazy_search_test.py
+++ b/tests/integration/element__lazy_search_test.py
@@ -23,11 +23,14 @@
from tests.integration.helpers.givenpage import GivenPage
-def test_search_does_not_start_on_creation(session_browser):
+def test_search_does_not_start_on_creation(
+ session_browser,
+):
page = GivenPage(session_browser.driver)
page.opened_empty()
- non_existent_element = session_browser.element('#not-existing-element-id')
+ non_existent_element = session_browser.element(
+ '#not-existing-element-id')
assert str(non_existent_element)
@@ -38,8 +41,14 @@ def test_search_is_postponed_until_actual_action_like_questioning_displayed(
page = GivenPage(session_browser.driver)
page.opened_empty()
- element = session_browser.element('#will-be-existing-element-id')
- page.load_body('Hello kitty:*
')
+ element = session_browser.element(
+ '#will-be-existing-element-id')
+ page.load_body(
+ '''
+ Hello kitty:*
+
+ '''
+ )
assert element().is_displayed() is True
@@ -50,11 +59,22 @@ def test_search_is_updated_on_next_actual_action_like_questioning_displayed(
page = GivenPage(session_browser.driver)
page.opened_empty()
- element = session_browser.element('#will-be-existing-element-id')
- page.load_body('Hello kitty:*
')
+ element = session_browser.element(
+ '#will-be-existing-element-id')
+ page.load_body(
+ '''
+ Hello kitty:
+ *
+ '''
+ )
+
assert element().is_displayed() is True
page.load_body(
- 'Hello kitty:*
'
+ '''
+ Hello kitty:
+ *
+ '''
)
+
assert element().is_displayed() is False
From 2b3e068ed32a63f8fd5661f4f69ad2a6d6772a26 Mon Sep 17 00:00:00 2001
From: Elena7788
Hello kitty:*
'''
)
- answer = element().is_displayed()
- assert answer is True
+ until_actual_action = element().is_displayed()
+
+ assert until_actual_action is True
def test_search_is_updated_on_next_actual_action_like_questioning_displayed(
session_browser,
):
- element = session_browser.element(
- '#will-be-existing-element'
- ).element('.will-exist-inner')
+ element = session_browser.element('#will-be-existing-element').element(
+ '.will-exist-inner'
+ )
page = GivenPage(session_browser.driver)
-
page.opened_with_body(
'''
@@ -70,26 +69,20 @@ def test_search_is_updated_on_next_actual_action_like_questioning_displayed(
'''
)
-
- assert element().is_displayed() is True
-
page.load_body(
'''
-
'''
)
- new_answer = element().is_displayed()
- assert new_answer is False
+ updated_actual_action = element().is_displayed()
+ assert updated_actual_action is False
-def test_search_finds_exactly_inside_parent(
- session_browser,
-):
+
+def test_search_finds_exactly_inside_parent(session_browser):
page = GivenPage(session_browser.driver)
page.opened_with_body(
'''
@@ -98,7 +91,7 @@ def test_search_finds_exactly_inside_parent(
kitty:*
+ kitty:*
go to Heading 2
Heading 1
Heading 2
- /p>
+