class RedmineHomeBreadcrumbPageElements:
    # Defining locators and webelements.

    link_home_breadcrum_loc = (By.XPATH, "//a[@href='/']")
    link_home_breadcrum = PageElement(link_home_breadcrum_loc)

    link_projects_breadcrum_loc = (By.XPATH, "//a[@href='/projects']")
    link_projects_breadcrum = PageElement(link_projects_breadcrum_loc)

    link_help_breadcrum_loc = (By.LINK_TEXT, "Help']")
    link_help_breadcrum = PageElement(link_help_breadcrum_loc)

    link_signin_breadcrum_loc = (By.XPATH, "//a[@href='/login']")
    link_signin_breadcrum = PageElement(link_signin_breadcrum_loc)

    link_register_breadcrum_loc = (By.XPATH, "//a[@href='/account/register']")
    link_register_breadcrum = PageElement(link_register_breadcrum_loc)

    link_mypage_breadcrum_loc = (By.XPATH, "//a[@href='/my/page']")
    link_mypage_breadcrumb = PageElement(link_mypage_breadcrum_loc)

    link_administration_breadcrum_loc = (By.XPATH, "//a[@href='/admin']")
    link_administration_breadcrum = PageElement(
        link_administration_breadcrum_loc)

    link_myaccount_breadcrum_loc = (By.XPATH, "//a[@href='/my/account']")
    link_myaccount_breadcrum = PageElement(link_myaccount_breadcrum_loc)

    link_signout_breadcrum_loc = (By.XPATH, "//a[@href='/account/register']")
    link_signout_breadcrum = PageElement(link_signout_breadcrum_loc)

    lbl_logged_as_loc = (By.ID, "loggedas")
    lbl_logged_as = PageElement(lbl_logged_as_loc)
Exemplo n.º 2
0
class BelaxPageElements:
    # Defining locators and webelements.
    lnk_contact_loc = (
        By.XPATH,
        "//div[@id='bs-example-navbar-collapse-1']//a[@title='Contact Us']")
    lnk_contact = PageElement(lnk_contact_loc)

    txt_first_name_loc = (By.XPATH, "//input[@name='FirstName']")
    txt_first_name = PageElement(txt_first_name_loc)

    txt_last_name_loc = (By.XPATH, "//input[@name='LastName']")
    txt_last_name = PageElement(txt_last_name_loc)

    txt_email_loc = (By.XPATH, "//input[@name='Email']")
    txt_email = PageElement(txt_email_loc)

    txt_phone_loc = (By.XPATH, "//input[@name='Phone']")
    txt_phone = PageElement(txt_phone_loc)

    txt_company_loc = (By.XPATH, "//input[@name='Company']")
    txt_company = PageElement(txt_company_loc)

    sel_service_loc = (By.XPATH, "//select[@name='ServicesNeeded']")
    sel_service = PageElement(sel_service_loc)

    txt_description_loc = (By.XPATH, "//textarea[@name='Description']")
    txt_description = PageElement(txt_description_loc)

    btn_submit_loc = (By.XPATH, "//button[@type='submit']")
    btn_submit = PageElement(btn_submit_loc)

    lbl_message_sent_loc = (By.XPATH,
                            "//h2[contains(.,'Thanks for your request!')]")
    lbl_message_sent = PageElement(lbl_message_sent_loc)
Exemplo n.º 3
0
class DashboardPageElements:
    # Defining locators and webelements.
    dashboard_title_loc = (By.XPATH, "//h1[contains(.,'Dashboard')]")
    lbl_dashboard_title = PageElement(dashboard_title_loc)

    user_name_loc = (By.ID, "txtUsername")
    txt_user_name = PageElement(user_name_loc)

    lnk_assign_leave_loc = (By.LINK_TEXT, "Assign Leave")
    lnk_assign_leave = PageElement(lnk_assign_leave_loc)

    lnk_leave_list_loc = (By.LINK_TEXT, "Leave List")
    lnk_leave_list = PageElement(lnk_leave_list_loc)

    lnk_timesheets_loc = (By.LINK_TEXT, "Timesheets")
    lnk_timesheets = PageElement(user_name_loc)

    img_assign_leave_loc = (By.XPATH, "//img[contains(@src,'ApplyLeave.png')]")
    img_assign_leave = PageElement(img_assign_leave_loc)

    img_leave_list_loc = (By.XPATH, "//img[contains(@src,'MyLeave.png')]")
    img_leave_list = PageElement(img_leave_list_loc)

    img_timesheets_loc = (By.XPATH, "//img[contains(@src,'MyTimesheet.png')]")
    img_timesheets = PageElement(user_name_loc)

    lbl_welcome_loc = (By.ID, "welcome")
    lbl_welcome = PageElement(lbl_welcome_loc)
Exemplo n.º 4
0
class OrangeLoginPageElements:
    # Defining locators and webelements.
    txt_user_name_loc = (By.ID, "txtUsername")
    txt_user_name = PageElement(txt_user_name_loc)

    txt_password_loc = (By.ID, "txtPassword")
    txt_password = PageElement(txt_password_loc)

    btn_login_loc = (By.XPATH, "//input[@id='btnLogin']")
    btn_login = PageElement(btn_login_loc)

    login_panel_loc = (By.ID, "logInPanelHeading")
    login_panel = PageElement(login_panel_loc)
Exemplo n.º 5
0
class RedmineAdminProjectsPageElements:
    # Defining locators and webelements.

    txt_project_name_loc = (By.XPATH, "//*[@id='name']")
    txt_project_name = PageElement(txt_project_name_loc)

    tbl_project_list_loc = (By.XPATH, "//div[@class='autoscroll']//tbody")
    tbl_project_list = PageElement(tbl_project_list_loc)

    delete_projects_bnt_list_loc = (By.XPATH, "//a[@data-method='delete']")
    delete_projects_bnt_list = MultiPageElement(delete_projects_bnt_list_loc)

    chk_confirm_delete_project_loc = (By.ID, "confirm")
    chk_confirm_delete_project = PageElement(chk_confirm_delete_project_loc)

    btn_delete_project_loc = (By.XPATH, "//input[@name='commit']")
    btn_delete_project = PageElement(btn_delete_project_loc)
Exemplo n.º 6
0
class IosGooglePageElement:

    txt_search_loc = (By.XPATH,
                      '//*[@id="tsf"]/div[2]/div/div[1]/div/div[1]/input')
    txt_search = PageElement(txt_search_loc)

    btn_search_loc = (By.XPATH,
                      '//div[@class="zGVn2e"]//button[@class="Tg7LZd"]')
    btn_search = PageElement(btn_search_loc)

    result_titles_list_loc = (By.XPATH,
                              '//*[@id="rso"]//div[@class="MUxGbd v0nnCb"]')
    '//*[@id="arc-srp_1920-0"]/div/div[3]/div[2]/div/div[1]/a/div[1]'
    result_titles_list = MultiPageElement(result_titles_list_loc)

    btn_more_results_loc = (By.XPATH,
                            '//*[@id="botstuff"]//span[@class="RVQdVd"]')
    btn_more_results = PageElement(btn_more_results_loc)
Exemplo n.º 7
0
class StevieAwardPageElements:
    # Defining locators and webelements.
    btn_vote_for_belatrix_loc = (By.XPATH, "//div[@class='gallery_col clearfix']/div[@class='gallery_desc ']//a[contains(.,'belatrix')]/parent::p/preceding-sibling::h3/a")
    btn_vote_for_belatrix = PageElement(btn_vote_for_belatrix_loc)

    lbl_nominated_company_loc = (By.XPATH, "//div[@class='voteConfirmation']/div[1]")
    lbl_nominated_company = PageElement(lbl_nominated_company_loc)

    lbl_confirm_your_selection_loc = (By.XPATH, "//*[@id='templateBody']//p")
    lbl_confirm_your_selection = PageElement(lbl_confirm_your_selection_loc)

    btn_confirm_vote_loc = (By.XPATH, "//input[@class='confirmVote button']")
    btn_confirm_vote = PageElement(btn_confirm_vote_loc)

    lbl_voting_confirmation_loc = (By.XPATH, "//div[@class='voteComplete']/div[1]/p")
    lbl_voting_confirmation = PageElement(lbl_voting_confirmation_loc)

    btn_cancel_and_go_back_loc = (By.XPATH, "//input[@class='back button']")
    btn_cancel_and_go_back = PageElement(btn_cancel_and_go_back_loc)
Exemplo n.º 8
0
class RedmineLoginPageElements:
    # Defining locators and webelements.
    btn_sign_in_loc = (By.XPATH, "//a[@class='login']")
    btn_sign_in = PageElement(btn_sign_in_loc)

    txt_user_name_loc = (By.ID, "username")
    txt_user_name = PageElement(txt_user_name_loc)

    txt_password_loc = (By.ID, "password")
    txt_password = PageElement(txt_password_loc)

    btn_login_loc = (By.XPATH, "//*[@id='login-submit']")
    btn_login = PageElement(btn_login_loc)

    login_panel_loc = (By.ID, "login-form")
    login_panel = PageElement(login_panel_loc)

    lbl_home_loc = (By.XPATH, "//*[@id ='content']")
    lbl_home = PageElement(lbl_home_loc)
Exemplo n.º 9
0
class CommonPageElements:
    # Defining locators and webelements.
    menu_admin_loc = (By.ID, "menu_admin_viewAdminModule")
    menu_admin = PageElement(menu_admin_loc)

    menu_pim_loc = (By.ID, "menu_pim_viewPimModule")
    menu_pim = PageElement(menu_pim_loc)

    menu_leave_loc = (By.ID, "menu_leave_viewLeaveModule")
    menu_leave = PageElement(menu_admin_loc)

    menu_time_loc = (By.ID, "menu_time_viewTimeModule")
    menu_time = PageElement(menu_time_loc)

    menu_recruitment_loc = (By.ID, "menu_recruitment_viewRecruitmentModule")
    menu_recruitment = PageElement(menu_recruitment_loc)

    menu_performance_loc = (By.ID, "menu__Performance")
    menu_performance = PageElement(menu_performance_loc)

    menu_dashboard_loc = (By.ID, "menu_dashboard_index")
    menu_dashboard = PageElement(menu_dashboard_loc)

    menu_directory_loc = (By.ID, "menu_directory_viewDirectory")
    menu_directory = PageElement(menu_directory_loc)

    # About Pop up
    btn_close_pop_up_loc = (By.XPATH, "//a[@class='close']")
    btn_close_pop_up = PageElement(btn_close_pop_up_loc)

    # Subsection
    menu_users_loc = (By.ID, "menu_admin_viewSystemUsers")
    menu_users = PageElement(menu_users_loc)

    menu_job_loc = (By.ID, "menu_admin_Job")
    menu_job = PageElement(menu_job_loc)

    menu_job_title_loc = (By.ID, "menu_admin_viewJobTitleList")
    menu_job_title = PageElement(menu_job_title_loc)

    menu_user_management_loc = (By.ID, "menu_admin_UserManagement")
    menu_user_management = PageElement(menu_user_management_loc)

    sel_user_options_loc = (By.XPATH, ".//*[@id='welcome-menu']/ul/li/a")
    sel_user_options = MultiPageElement(sel_user_options_loc)

    # Welcome user select menu
    sel_welcome_loc = (By.ID, "welcome")
    sel_welcome = PageElement(sel_welcome_loc)
    section_user_options_loc = (By.ID, "welcome-menu")
    section_user_options = PageElement(section_user_options_loc)

    btn_about_loc = (By.ID, "aboutDisplayLink")
    btn_about = PageElement(btn_about_loc)

    btn_change_password_loc = (By.XPATH, "//a[contains(.,'Change Password')]")
    btn_change_password = PageElement(btn_change_password_loc)

    btn_logout_loc = (By.XPATH, "//a[contains(.,'Logout')]")
    btn_logout = PageElement(btn_logout_loc)
class Way2AutomationPageElements:
    img_logo_loc = (By.XPATH, r"//img[@src='demo/images/logo.png']")
    img_logo = PageElement(img_logo_loc)

    lbl_title_loc = (
        By.XPATH,
        r"//h1[contains(.,'Website for Testing Selenium / QTP scripts')]")
    lbl_title = PageElement(lbl_title_loc)

    block_registration_form_loc = (By.ID, r"load_box")
    block_registration_form = PageElement(block_registration_form_loc)

    txt_name_loc = (By.NAME, r"name")
    txt_name = PageElement(txt_name_loc)

    txt_phone_loc = (By.NAME, r"phone")
    txt_phone = PageElement(txt_phone_loc)

    txt_email_loc = (By.NAME, r"email")
    txt_email = PageElement(txt_email_loc)

    sel_country_loc = (By.NAME, r"country")
    sel_country = PageElement(sel_country_loc)

    txt_city_loc = (By.NAME, r"city")
    txt_city = PageElement(txt_city_loc)

    txt_username_loc = (By.XPATH,
                        r"//div[@id='load_box']//input[@name='username']")
    txt_username = PageElement(txt_username_loc)

    txt_password_loc = (By.XPATH,
                        r"//div[@id='load_box']//input[@name='password']")
    txt_password = PageElement(txt_password_loc)

    btn_submit_loc = (By.XPATH,
                      r"//div[@id='load_box']//input[@type='submit']")
    btn_submit = PageElement(btn_submit_loc)

    # MENU #
    # <<<<Alert>>>>
    menu_alert_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Alert')]")
    menu_alert = PageElement(menu_alert_loc)

    # <<<<Registration>>>>
    menu_registration_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Registration')]")
    menu_registration = PageElement(menu_registration_loc)

    # <<<<Dynamic Elements>>>>
    menu_dynamic_elements_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Dynamic Elements')]"
    )
    menu_dynamic_elements = PageElement(menu_dynamic_elements_loc)

    menu_submit_button_clicked_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Submit Button Clicked')]"
    )
    menu_submit_button_clicked = PageElement(menu_submit_button_clicked_loc)
    menu_dropdown_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Dropdown')]")
    menu_dropdown = PageElement(menu_dropdown_loc)

    # <<<<Frames and Windows>>>>
    menu_frames_and_windows_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Frames and Window')]"
    )
    menu_frames_and_windows = PageElement(menu_frames_and_windows_loc)

    # <<<<Widget>>>>
    menu_widget_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Widget')]")
    menu_widget = PageElement(menu_widget_loc)

    # <<<<Interaction>>>>
    menu_interaction_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Interaction')]")
    menu_interaction = PageElement(menu_interaction_loc)

    menu_draggable_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Draggable')]")
    menu_draggable = PageElement(menu_draggable_loc)

    menu_droppable_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Droppable')]")
    menu_droppable = PageElement(menu_droppable_loc)

    menu_resizable_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Resizable')]")
    menu_resizable = PageElement(menu_resizable_loc)

    menu_selectable_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Selectable')]")
    menu_selectable = PageElement(menu_selectable_loc)

    menu_sortable_loc = (
        By.XPATH,
        r"//div[@class='container main-nav']//a[contains(.,'Sortable')]")
    menu_sortable = PageElement(menu_sortable_loc)

    # ALERTS #
    btn_display_alert_loc = (By.XPATH,
                             r"//body/button[@onclick='myFunction()']")
    btn_display_alert = PageElement(btn_display_alert_loc)
    tab_simple_alert_loc = (By.XPATH, r"//a[contains(.,'Simple Alert')]")
    tab_simple_alert = PageElement(tab_simple_alert_loc)
    tab_input_alert_loc = (By.XPATH, r"//a[contains(.,'Input Alert')]")
    tab_input_alert = PageElement(tab_input_alert_loc)

    # Dynamic Elements #
    tab_starts_with_loc = (By.XPATH, r"//a[contains(.,'Starts With')]")
    tab_starts_with = PageElement(tab_starts_with_loc)

    tab_ends_with_loc = (By.XPATH, r"//a[contains(.,'Ends With')]")
    tab_ends_with = PageElement(tab_ends_with_loc)

    tab_complete_id_dynamic_loc = (By.XPATH,
                                   r"//a[contains(.,'Complete id Dynamic')]")
    tab_complete_id_dynamic = PageElement(tab_complete_id_dynamic_loc)

    txt_form_input_loc = (By.XPATH, r"//input[@type='text']")
    txt_form_input = PageElement(txt_form_input_loc)

    btn_form_submit_loc = (By.XPATH, r"//input[@class='submit']")
    btn_form_submit = PageElement(btn_form_submit_loc)
class RedmineAdministrationPageElements:
    # Defining locators and webelements.
    btn_project_loc = (By.XPATH, "//a[@class='icon icon-projects projects']")
    btn_project = PageElement(btn_project_loc)
Exemplo n.º 12
0
class AdminUserPageElements:
    # Defining locators and webelements.
    txt_username_loc = (By.ID, "searchSystemUser_userName")
    txt_username = PageElement(txt_username_loc)

    sel_user_role_loc = (By.ID, "searchSystemUser_userType")
    sel_user_role = PageElement(sel_user_role_loc)

    txt_employee_name_loc = (By.ID, "searchSystemUser_employeeName_empName")
    txt_employee_name = PageElement(txt_employee_name_loc)

    txt_employee_name_id_loc = (By.ID, "searchSystemUser_userName")
    txt_employee_name_id = PageElement(txt_employee_name_id_loc)

    sel_status_loc = (By.ID, "searchSystemUser_status")
    sel_status = PageElement(sel_status_loc)

    btn_search_loc = (By.ID, "searchBtn")
    btn_search = PageElement(btn_search_loc)

    btn_reset_loc = (By.ID, "resetBtn")
    btn_reset = PageElement(btn_reset_loc)

    btn_add_job_loc = (By.ID, "btnAdd")
    btn_add_job = PageElement(btn_add_job_loc)

    btn_select_all_loc = (By.ID, "ohrmList_chkSelectAll")
    chk_select_all = PageElement(btn_select_all_loc)

    lbl_system_users_loc = (By.XPATH, "//div[@class='head']")
    lbl_system_users = PageElement(lbl_system_users_loc)

    tbl_user_search_result_loc = (By.XPATH,
                                  "//table[@id='resultTable']//tbody")
    tbl_user_search_result = PageElement(tbl_user_search_result_loc)

    user_links_loc = (By.LINK_TEXT, "username")

    "//table/tbody/tr/td[contains(.,'Enabled')]"
Exemplo n.º 13
0
class RedmineProjectsPageElements:
    # Defining locators and webelements.
    btn_new_project_loc = (By.XPATH, "//a[text()='New project']")
    btn_new_project = PageElement(btn_new_project_loc)

    txt_project_name_loc = (By.ID, "project_name")
    txt_project_name = PageElement(txt_project_name_loc)

    __txt_project_description_loc = (By.ID, "project_description")
    txt_project_description = PageElement(__txt_project_description_loc)

    __txt_project_identifier_loc = (By.ID, "project_identifier")
    txt_project_identifier = PageElement(__txt_project_identifier_loc)

    __txt_homepage_loc = (By.ID, "project_homepage")
    txt_homepage = PageElement(__txt_homepage_loc)

    __chk_public_loc = (By.ID, "project_is_public")
    chk_public = PageElement(__chk_public_loc)

    __sel_subproject_of_loc = (By.ID, "project_parent_id")
    sel_subproject_of = PageElement(__sel_subproject_of_loc)

    chk_inherit_members_loc = (By.ID, "project_inherit_members")
    chk_inherit_members = PageElement(chk_inherit_members_loc)

    __chk_modules_list_loc = (
        By.XPATH,
        "//legend[text()='Modules']/parent::fieldset//input[@type='checkbox']")
    chk_modules_list = MultiPageElement(__chk_modules_list_loc)

    __chk_trackers_list_loc = (
        By.XPATH,
        "//legend[text()='Trackers']/parent::fieldset//input[@type='checkbox']"
    )
    chk_trackers_list = MultiPageElement(__chk_trackers_list_loc)

    btn_create_loc = (By.NAME, "commit")
    btn_create = PageElement(btn_create_loc)

    __btn_create_and_continue_loc = (By.NAME, "continue")
    btn_create_and_continue = PageElement(__btn_create_and_continue_loc)

    __btn_save_loc = (By.XPATH,
                      "//form[@id='edit_project_5']/input[@value='Save']")
    btn_save = PageElement(__btn_save_loc)

    lbl_message_loc = (By.ID, "flash_notice")
    lbl_message = PageElement(lbl_message_loc)

    __tbl_projects_list_loc = (By.XPATH, "//*[@id='projects-index']//a")
    tbl_projects_list = MultiPageElement(__tbl_projects_list_loc)
Exemplo n.º 14
0
class RedmineHomepagePageElements:

    menu_home_loc = (By.XPATH, "//a[@href='/']")
    menu_home = PageElement(menu_home_loc)

    menu_my_page_loc = (By.XPATH,"//a[@href='/my/page']")
    menu_my_page = PageElement(menu_my_page_loc)

    menu_projects_loc = (By.XPATH,"//a[@href='/projects']")
    menu_projects = PageElement(menu_projects_loc)

    menu_administration_loc = (By.XPATH,"//a[@href='/admin']")
    menu_administration = PageElement(menu_administration_loc)

    menu_help_loc = (By.XPATH,"//a[@href='https://www.test_redmine.org/guide']")
    menu_help = PageElement(menu_help_loc)

    menu_my_account_loc = (By.XPATH, "//a[@href='/my/account']")
    menu_my_account = PageElement(menu_my_account_loc)

    menu_sign_in_loc = (By.XPATH, "//a[@href='/login']")
    menu_sign_in = PageElement(menu_sign_in_loc)

    menu_register_loc = (By.XPATH, "//a[@href='/account/register']")
    menu_register = PageElement(menu_register_loc)

    menu_logout_loc = (By.XPATH, "//a[@href='/logout']")
    menu_logout = PageElement(menu_logout_loc)

    lbl_home_page_label_loc = (By.XPATH, "//div[@id='content']/h2")
    lbl_home_page_label = PageElement(lbl_home_page_label_loc)

    lbl_logged_as_loc = (By.ID, "loggedas")
    lbl_logged_as = PageElement(lbl_logged_as_loc)

    menu_mobile_emulation_menu_button_loc = (By.CSS_SELECTOR, "#header > a")
    menu_mobile_emulation_menu_button = PageElement(menu_mobile_emulation_menu_button_loc)

    menu_mobile_emulation_panel_loc = (By.XPATH, "//*[@class='flyout-menu js-flyout-menu']")
    menu_mobile_emulation_panel = PageElement(menu_mobile_emulation_panel_loc)