Exemple #1
0
 def count_social_media_imgs_v2(self):
     elements = Utils.find_elements(self.driver, By.CSS_SELECTOR,
                                    '.buttons-w span')
     count = 0
     for x in elements:
         count = count + 1
     return count
Exemple #2
0
 def get_warning_msg(self):
     element = Utils.wait_presence_and_get_element(self.driver,
                                                   By.CSS_SELECTOR,
                                                   '.alert-warning')
     text = None
     if element is not None:
         text = element.text
     return text
Exemple #3
0
 def get_remember_me_label_text(self):
     return Utils.wait_presence_and_get_element(self.driver,
                                                By.CSS_SELECTOR,
                                                '.form-check-label')
Exemple #4
0
 def remember_me_button_is_clickable(self):
     return Utils.wait_clickable_and_get_element(self.driver,
                                                 By.CSS_SELECTOR,
                                                 '.form-check-input')
Exemple #5
0
 def get_login_button(self):
     return Utils.wait_presence_and_get_element(self.driver, By.ID,
                                                'log-in')
Exemple #6
0
 def password_img_is_present(self):
     return Utils.wait_presence_and_get_element(
         self.driver, By.CSS_SELECTOR, '.form-group:nth-child(2) .pre-icon')
Exemple #7
0
 def get_password_box(self):
     return Utils.wait_presence_and_get_element(self.driver, By.ID,
                                                'password')
Exemple #8
0
 def click_amount_header(self):
     amount_header = Utils.wait_presence_and_get_element(self.driver, By.ID, 'amount')
     amount_header.click()
Exemple #9
0
 def username_img_is_present(self):
     return Utils.wait_presence_and_get_element(self.driver,
                                                By.CSS_SELECTOR,
                                                '.form-group .pre-icon')
Exemple #10
0
 def get_username_box(self):
     return Utils.wait_presence_and_get_element(self.driver, By.ID,
                                                'username')
Exemple #11
0
 def username_label_is_present(self):
     element = Utils.wait_presence_and_get_element(self.driver,
                                                   By.CSS_SELECTOR,
                                                   '.form-group label')
     return element.text
Exemple #12
0
 def get_title(self, title):
     element = Utils.wait_presence_and_get_element(self.driver,
                                                   By.CSS_SELECTOR,
                                                   '.auth-header')
     return element.text
Exemple #13
0
 def logo_big_img_is_present(self):
     return Utils.wait_presence_and_get_element(self.driver,
                                                By.CSS_SELECTOR,
                                                '.logo-w img')
Exemple #14
0
 def flash_sale2_is_present(self):
     return Utils.wait_presence_and_get_element(self.driver, By.CSS_SELECTOR, '#flashSale2 img')
Exemple #15
0
 def click_compare_expenses(self):
     compare_expenses = Utils.wait_clickable_and_get_element(self.driver, By.ID, 'showExpensesChart')
     compare_expenses.click()
Exemple #16
0
 def password_label_is_present(self):
     element = Utils.wait_presence_and_get_element(
         self.driver, By.CSS_SELECTOR, '.form-group:nth-child(2)')
     return element.text
Exemple #17
0
 def click_show_next_year_button(self):
     button = Utils.wait_presence_and_get_element(self.driver, By.ID, 'addDataset')
     button.click()
Exemple #18
0
 def user_is_logged_in(self):
     return Utils.wait_presence_and_get_element(self.driver, By.CSS_SELECTOR, '.avatar-w')