コード例 #1
0
    def test_not_checked_privacy_policy(self):
        register_page = RegisterPage(self.driver)

        register_page.enter_email(Variables.VALID_EMAIL)
        register_page.enter_password_confirm(Variables.VALID_PASSWORD)
        register_page.enter_password_confirm(Variables.VALID_PASSWORD)
        register_page.click_register_button()

        register_page.error_should_be_visible(Variables.ACCEPT_PRIVACY_MESSAGE)
コード例 #2
0
    def test_empty_email(self):
        register_page = RegisterPage(self.driver)

        register_page.enter_password(Variables.VALID_PASSWORD)
        register_page.enter_password_confirm(Variables.VALID_PASSWORD)
        register_page.accept_privacy_policy()
        register_page.click_register_button()

        register_page.email_should_be_required()
コード例 #3
0
    def test_different_passwords(self):
        register_page = RegisterPage(self.driver)

        register_page.enter_email(Variables.VALID_EMAIL)
        register_page.enter_password_confirm(Variables.VALID_PASSWORD)
        register_page.enter_password_confirm(Variables.OTHER_PASSWORD)
        register_page.accept_privacy_policy()
        register_page.click_register_button()

        register_page.error_should_be_visible(
            Variables.PASSWORD_NOT_MATCH_MESSAGE)
コード例 #4
0
    def test_short_password(self):
        register_page = RegisterPage(self.driver)

        register_page.enter_email(Variables.VALID_EMAIL)
        register_page.enter_password(Variables.SHORT_PASSWORD)
        register_page.enter_password_confirm(Variables.SHORT_PASSWORD)
        register_page.accept_privacy_policy()
        register_page.click_register_button()

        register_page.error_should_be_visible(
            Variables.PASSWORD_TOO_SHORT_MESSAGE)
コード例 #5
0
    def test_existing_email(self):
        register_page = RegisterPage(self.driver)

        register_page.enter_email(Variables.VALID_EMAIL)
        register_page.enter_password(Variables.VALID_PASSWORD)
        register_page.enter_password_confirm(Variables.VALID_PASSWORD)
        register_page.accept_privacy_policy()
        register_page.click_register_button()

        register_page.error_should_be_visible(
            Variables.USER_ALREADY_EXISTS_MESSAGE)