Created
May 16, 2017 20:55
-
-
Save evanniedojadlo/3651561be831a5d6f57ecdba4496efb9 to your computer and use it in GitHub Desktop.
resides in /pages
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from selenium.webdriver.common.by import By | |
from base_page import BasePage | |
class SellerPage(BasePage): | |
_login_form = {"by": By.ID, "value": "navbar-collapse"} | |
_username_input = {"by": By.ID, "value": "loginEmailInput"} | |
_password_input = {"by": By.ID, "value": "loginPasswordInput"} | |
_submit_button = {"by": By.ID, "value": "loginBtn"} | |
_success_message = {"by": By.CSS_SELECTOR, "value": ".myofferPanelBody"} | |
_failure_message = {"by": By.ID, "value": "loginErrorMsg"} | |
_year_input = {"by": By.ID, "value": "yearInput"} | |
_make_input = {"by": By.ID, "value": "makeInput"} | |
_model_input = {"by": By.ID, "value": "modelInput"} | |
_search_by_vin = {"by": By.CSS_SELECTOR, "value": "list-group-item panelListItem tab-index-flow"} | |
_clean_title_ = {"by": By.ID, "value": "titleTypeCheckboxYesPanelListId"} | |
def ___init___(self, driver): | |
self.driver = driver | |
#self._visit("/sell-car#0") | |
#assert self._is_displayed(self._login_form) #assert that we are on the landing right page | |
# #def with_(self, username, password): | |
# self._type(self._username_input, username) | |
# self._type(self._password_input, password) | |
# self._click(self._submit_button) | |
# #def success_message_present(self): | |
# self._wait_for_is_displayed(self._success_message, 1) | |
# return self._is_displayed(self._success_message) | |
# #def failure_message_present(self): | |
# self._wait_for_is_displayed(self._failure_message, 1) | |
# return self._is_displayed(self._failure_message) | |
# #def post_slack_message(self, script_name, is_failed, slack_message): | |
# self.slack_post_automation(script_name, is_failed, slack_message) | |
def load_example(self, navigate): | |
self._visit("/sell-car#0/") | |
def enter_year_with(self, year): | |
self._click(self._year_input) | |
self._type(self._year_input) | |
#click find a year | |
#enter year | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment