Esempio n. 1
0
 def check_cl_after_lineitem_added():
     template_name = Constants.Dashboard.LeftPanel.\
         EditChecklistTemplate.HEAT
     user_content = APIVirtualFunction.create_engagement()
     FEUser.login(Constants.Users.Admin.EMAIL,
                  Constants.Default.Password.TEXT)
     vfName = user_content['vfName']
     engagement_id = DBChecklist.fetchEngByVfName(vfName)
     engLeadEmail = DBUser.select_el_email(vfName)
     engagement_manual_id = DBChecklist.fetchEngManIdByEngUuid(
         engagement_id)
     FEOverview.click_on_vf(user_content)
     FEGeneral.re_open(Constants.Default.LoginURL.TEXT)
     FEUser.login(engLeadEmail, Constants.Default.Password.TEXT,
                  engagement_manual_id)
     Click.id(
         Constants.Dashboard.LeftPanel.EditChecklistTemplate.DASHBOARD_ID)
     Enter.text_by_id(
         Constants.Dashboard.LeftPanel.EditChecklistTemplate.SEARCH_ENG_ID,
         vfName)
     Click.id("test_" + vfName)
     checklistName = FEChecklist.create_checklist(engagement_id, vfName,
                                                  None,
                                                  engagement_manual_id)
     FEUser.go_to_admin()
     result = DBChecklist.fetchChecklistByName(checklistName)
     FEUser.go_to_admin()
     FEChecklistTemplate.click_on_template_name_on_navigation(
         Constants.Dashboard.LeftPanel.EditChecklistTemplate.HEAT,
         template_name)
     Click.id(Constants.Dashboard.LeftPanel.EditChecklistTemplate.
              EDIT_LINE_ITEM_BTN)
     Enter.text_by_id(
         Constants.Dashboard.LeftPanel.EditChecklistTemplate.
         EDIT_LINE_ITEM_NAME,
         "test_lineitem_added_and_audit_log_on_dupl_cl-NAME")
     Click.id(Constants.Dashboard.LeftPanel.EditChecklistTemplate.
              EDIT_LINE_ITEM_BTN)
     FEChecklistTemplate.click_on_save_and_assert_success_msg()
     Click.id(
         Constants.Dashboard.LeftPanel.EditChecklistTemplate.DASHBOARD_ID)
     Enter.text_by_id(
         Constants.Dashboard.LeftPanel.EditChecklistTemplate.SEARCH_ENG_ID,
         vfName)
     Click.id("test_" + vfName)
     Click.id("checklist-" + str(result))
     Helper.internal_assert(
         "1. automation",
         session.ice_driver.find_element_by_xpath("//li[@id='']").text)
Esempio n. 2
0
 def basic_admin_navigation():
     FEUser.login(Constants.Users.Admin.EMAIL,
                  Constants.Default.Password.TEXT)
     FEUser.go_to_admin()