def login_with_github(self, email, password, secret): auth0 = Auth0(self.base_url, self.selenium) auth0.click_login_with_github() auth0.enter_github_email(email) auth0.enter_github_password(password) auth0.click_github_sign_in() auth0.enter_github_passcode(secret)
def login_with_firefox_accounts(self, email, password, secret): auth0 = Auth0(self.base_url, self.selenium) auth0.click_login_with_firefox_accounts() auth0.enter_fxa_email(email) auth0.enter_fxa_password(password) auth0.click_firefox_accounts_sign_in() auth0.enter_fxa_passcode(secret)
def login(self, email_address): self.click_sign_in_button() auth0 = Auth0(self.selenium, self.base_url) auth0.request_login_link(email_address) login_link = restmail.get_mail(email_address) self.selenium.get(login_link) self.wait.until(lambda s: self.is_user_loggedin)
def login_with_ldap(self, email, password): self.selenium.find_element(*self._sign_in_button_locator).click() self.wait_for_element_visible(*self._sign_in_to_standup_button_locator) self.selenium.find_element(*self._sign_in_to_standup_button_locator).click() auth = Auth0(self.selenium) auth.login_with_ldap(email, password) return TwoFactorAuthentication(self.selenium)
def login_with_github(self, username, password, secret): auth0 = Auth0(self.base_url, self.selenium) auth0.click_login_with_github() auth0.enter_github_username(username) auth0.enter_github_password(password) auth0.click_github_sign_in() auth0.enter_github_passcode(secret)
def login_with_google(self, email, password): auth0 = Auth0(self.base_url, self.selenium) auth0.click_login_with_google() auth0.enter_google_email(email) auth0.click_email_next() auth0.enter_google_password(password) auth0.click_password_next()
def login_with_ldap(self, email_address, password): auth0 = Auth0(self.base_url, self.selenium) auth0.enter_email(email_address) auth0.click_email_enter() auth0.enter_ldap_password(password) auth0.click_enter_button() return TwoFactorAuthenticationPage(self.base_url, self.selenium)
def login_passwordless(self, email_address): auth0 = Auth0(self.base_url, self.selenium) auth0.enter_email(email_address) auth0.click_email_enter() auth0.click_send_email() login_link = conftest.login_link(email_address) self.selenium.get(login_link)
def login_with_ldap(self, email_address, password, secret): auth0 = Auth0(self.base_url, self.selenium) auth0.enter_email(email_address) auth0.click_email_enter() auth0.enter_ldap_password(password) auth0.click_enter_button() auth0.enter_ldap_passcode(secret)
def add_email(self, email): self.selenium.find_element(*self._add_email_button_locator).click() auth0 = Auth0(self.base_url, self.selenium) auth0.request_login_link(email) login_link = conftest.login_link(email) self.selenium.get(login_link) return self
def login(self, email): self.click_sign_in_button() auth0 = Auth0(self.selenium, self.base_url) auth0.request_login_link(email) login_link = conftest.login_link(email) self.selenium.get(login_link) self.wait.until(lambda s: self.is_user_loggedin)
def click_discourse(self, message): initial_windows = len(self.selenium.window_handles) self.selenium.find_element(*self._discourse_app_locator).click() WebDriverWait(self.selenium, self.timeout).until( lambda s: len(self.selenium.window_handles) == initial_windows + 1) self.selenium.switch_to.window(self.selenium.window_handles[1]) auth = Auth0(self.base_url, self.selenium) auth.wait_for_message(message) return Discourse(self.base_url, self.selenium)
def login_with_firefox_accounts(self, email, password, secret): auth0 = Auth0(self.base_url, self.selenium) if self.base_url == "https://social-ldap-pwless.testrp.security.allizom.org": auth0.login_with_fxa_staging(email, password, secret) else: auth0.click_login_with_firefox_accounts() auth0.enter_fxa_email(email) auth0.enter_fxa_password(password) auth0.click_firefox_accounts_sign_in() auth0.enter_fxa_passcode(secret)
def auth(self): return Auth0(self.base_url, self.selenium)
def login_with_ldap(self, email, password): self.selenium.find_element(*self._login_button_locator).click() auth = Auth0(self.selenium) auth.login_with_ldap(email, password) return TwoFactorAuthentication(self.selenium)
def click_discourse(self, message): self.selenium.find_element(*self._discourse_app_locator).click() self.selenium.switch_to.window(self.selenium.window_handles[1]) auth = Auth0(self.base_url, self.selenium) auth.wait_for_message(message) return Discourse(self.base_url, self.selenium)
def login_with_ldap(self, email, password): self.selenium.find_element(*self._sign_in_button).click() auth = Auth0(self.selenium) auth.login_with_ldap(email, password, ldap_only=True) return TwoFactorAuthentication(self.selenium)
def login_with_ldap(self, email, password): auth = Auth0(self.selenium) auth.login_with_ldap(email, password, ldap_only=True) return TwoFactorAuthentication(self.selenium)
def login_with_github(self, username, password, secret): self.click_sign_in_button() auth0 = Auth0(self.selenium, self.base_url) github = auth0.click_login_with_github() github.login_with_github(username, password, secret)
def ldap_login(self, email_address, password): self.click_sign_in_button() auth0 = Auth0(self.base_url, self.selenium) auth0.login_with_ldap(email_address, password) return TwoFactorAuthenticationPage(self.base_url, self.selenium)
def login(self, email, password, secret_seed): auth0 = Auth0(self.selenium, self.base_url) auth0.enter_email(email) auth0.enter_password(password) auth0.enter_passcode(secret_seed)
def click_sign_in_button(self): self.selenium.find_element(*self._sign_in_button).click() return Auth0(self.base_url, self.selenium)