Example #1
0
 def test_repeatSelectExistingTasks_succeed_run11(self):
     '''选择已有任务,重新选择后,验证是否成功'''
     self.login()
     me = ManualEntry(self.driver)
     me.clickMyTes()
     me.clickManualDetectButton()
     sleep(2)
     me.clickChooseBtn()
     me.clickDropDownBtn()
     me.clickOldTaskchoise()
     me.clickConfirmTaskBtn()
     me.clickRechoiseBtn()
     try:
         self.assertTrue(me.isRechoiseClickable(), "-----重新选择不可点击------")
         me.clickDropDownBtn()
         rechoise_name = me.clickSecendOldTaskchoise()
         me.clickConfirmTaskBtn()
         confirm_name = me.getCreatTaskName()
         self.assertEqual(rechoise_name, confirm_name,
                          "-----重新选择已有任务失败-----")
     finally:
         imagetest = getResultImage()
         imagetest.insert_image(self.driver,
                                "repeatSelectExistingTasks_succeed.jpg")
         sleep(3)
Example #2
0
 def test_creatNewTask_succeed_run01(self):
     '''新建任务成功'''
     self.login()
     me = ManualEntry(self.driver)
     me.clickMyTes()
     me.clickManualDetectButton()
     task_name = me.getDifferName()
     me.inputCreatTaskBox(task_name)
     me.clickConfirmTaskBtn()
     confirm_name = me.getCreatTaskName()
     try:
         self.assertEqual(task_name, confirm_name, "-----新建任务失败-----")
     finally:
         imagetest = getResultImage()
         imagetest.insert_image(self.driver, "creatNewTask_succeeful.jpg")
         sleep(3)
Example #3
0
 def test_selectExistingTasks_succeed_run02(self):
     '''选择已有任务成功'''
     self.login()
     me = ManualEntry(self.driver)
     me.clickMyTes()
     me.clickManualDetectButton()
     sleep(5)
     me.clickChooseBtn()
     me.clickDropDownBtn()
     old_name = me.clickOldTaskchoise()
     me.clickConfirmTaskBtn()
     confirm_name = me.getCreatTaskName()
     try:
         self.assertEqual(old_name, confirm_name, "-----选择已有任务失败-----")
     finally:
         imagetest = getResultImage()
         imagetest.insert_image(self.driver,
                                "selectExistingTasks_succeed.jpg")
         sleep(3)
Example #4
0
 def test_modifyCreatNewTask_succeed_run08(self):
     '''新建任务后,对任务名称进行修改'''
     self.login()
     me = ManualEntry(self.driver)
     me.clickMyTes()
     me.clickManualDetectButton()
     task_name = me.getDifferName()
     me.inputCreatTaskBox(task_name)
     me.clickConfirmTaskBtn()
     me.clickModifyBtn()
     modify_name = me.getDifferName()
     me.inputCreatTaskBox(modify_name)
     me.clickConfirmTaskBtn()
     confirm_name = me.getCreatTaskName()
     try:
         self.assertEqual(modify_name, confirm_name,
                          "------修改任务名称失败--------")
     finally:
         imagetest = getResultImage()
         imagetest.insert_image(self.driver,
                                "modifyCreatNewTask_succeed.jpg")
         sleep(3)