diff --git a/tests/ui/test_home_ui.py b/tests/ui/test_home_ui.py index bd89c08b..3f781019 100644 --- a/tests/ui/test_home_ui.py +++ b/tests/ui/test_home_ui.py @@ -14,10 +14,8 @@ def test_home_ui(chrome_page, github_user, github_password, gitpod_repo_url): chrome_page.goto(gitpod_repo_url) home = HomePoet(chrome_page) - if not home.continue_with_github_is_visible: - pass - - home.click_continue_with_github_button() + if home.continue_with_github_is_visible: + home.click_continue_with_github_button() with chrome_page.context.pages[1] as github_login_window: github_login_window.fill("#login_field", github_user) @@ -25,10 +23,7 @@ def test_home_ui(chrome_page, github_user, github_password, gitpod_repo_url): github_login_window.click(sign_in_button_selector) - if home.gitpod_user_dropdown.inner_text() == "0 openstax": - pass - - else: + if home.gitpod_user_dropdown.inner_text() != "0 openstax": home.click_gitpod_user_dropdown() home.click_gitpod_user_selector() diff --git a/tests/ui/test_readme_validate_other_features.py b/tests/ui/test_readme_validate_other_features.py index a01bf12a..8137aee5 100644 --- a/tests/ui/test_readme_validate_other_features.py +++ b/tests/ui/test_readme_validate_other_features.py @@ -16,10 +16,8 @@ def test_readme_validate_other_features( chrome_page.goto(gitpod_repo_url) home = HomePoet(chrome_page) - if not home.continue_with_github_is_visible: - pass - - home.click_continue_with_github_button() + if home.continue_with_github_is_visible: + home.click_continue_with_github_button() with chrome_page.context.pages[1] as github_login_window: github_login_window.fill("#login_field", github_user) @@ -27,10 +25,7 @@ def test_readme_validate_other_features( github_login_window.click(sign_in_button_selector) - if home.gitpod_user_dropdown.inner_text() == "0 openstax": - pass - - else: + if home.gitpod_user_dropdown.inner_text() != "0 openstax": home.click_gitpod_user_dropdown() home.click_gitpod_user_selector() diff --git a/tests/ui/test_toc_editor.py b/tests/ui/test_toc_editor.py index 429092ec..9977accd 100644 --- a/tests/ui/test_toc_editor.py +++ b/tests/ui/test_toc_editor.py @@ -15,10 +15,8 @@ def test_toc_editor(chrome_page, github_user, github_password, gitpod_repo_url): home = HomePoet(chrome_page) # WHEN: login into openstax/osbooks-otto-book repo - if not home.continue_with_github_is_visible: - pass - - home.click_continue_with_github_button() + if home.continue_with_github_is_visible: + home.click_continue_with_github_button() with chrome_page.context.pages[1] as github_login_window: github_login_window.fill("#login_field", github_user) @@ -26,10 +24,7 @@ def test_toc_editor(chrome_page, github_user, github_password, gitpod_repo_url): github_login_window.click(sign_in_button_selector) - if home.gitpod_user_dropdown.inner_text() == "0 openstax": - pass - - else: + if home.gitpod_user_dropdown.inner_text() != "0 openstax": home.click_gitpod_user_dropdown() home.click_gitpod_user_selector()