def test_2_financeBookInfo_submit(self):
        self.user_login_verify()
        my_client = myClient(self.driver)
        my_client.gotoMyClientList_All(Data.lnk_moblie)
        my_client.setWaitTime(2)
        # self.assertEqual(my_client.search_by_fuzzy(),'自动化测试有限公司')
        functions.insert_img(self.driver,
                             current_time + "__myClient_aftersearch.png")

        fin_book = finceBookInfo(self.driver)  #打开需求书
        fin_book.submitFinanceBookInfo()
        fin_book.setWaitTime(2)
        functions.insert_img(
            self.driver, current_time + "__financeBookInfo_afterSubmit.png")
        # fin_book.close()

        #校验需求书是否保存成功
        self.user_login_verify()
        my_client = myClient(self.driver)
        my_client.gotoMyClientList_All(Data.lnk_moblie)
        my_client.setWaitTime(2)
        # self.assertEqual(my_client.search_by_fuzzy(),Data.cmp_name)
        functions.insert_img(
            self.driver, current_time + "__myClient_verifyFinBookSubmit.png")
        my_client.setWaitTime(2)
        my_client.close()
    def test_2_financeBookInfo_submit(self):
        user = init.getUser('销售顾问')
        self.user_login_verify(username=user['username'],
                               password=user['password'],
                               city=user['city'])
        my_client = myClient(self.driver)
        my_client.gotoMyClientList_All(init.getClient('新客户')['lnk_mobile'])
        my_client.setWaitTime(2)
        self.assertEqual(my_client.search_by_fuzzy(), '大坤哥自动化')
        functions.insert_img(self.driver,
                             current_time + "__myClient_aftersearch.png")

        fin_book = finceBookInfo(self.driver)  #打开需求书
        fin_book.submitFinanceBookInfo()
        fin_book.setWaitTime(2)
        functions.insert_img(
            self.driver, current_time + "__financeBookInfo_afterSubmit.png")
        # fin_book.close()

        #校验需求书是否保存成功
        self.user_login_verify(username=user['username'],
                               password=user['password'],
                               city=user['city'])
        my_client = myClient(self.driver)
        my_client.gotoMyClientList_All(init.getClient('新客户')['lnk_mobile'])
        my_client.setWaitTime(2)
        self.assertEqual(fin_book.verify_finceBookInfo_save_success(),
                         init.getClient('新客户')['lnk_mobile'])
        functions.insert_img(
            self.driver, current_time + "__myClient_verifyFinBookSubmit.png")
        my_client.setWaitTime(2)
        my_client.close()
Exemplo n.º 3
0
def step_submitFinceBookInfo(context):
    global fb
    fb = finceBookInfo(context.driver)  # 打开需求书
    fb.submitFinanceBookInfo()
    fb.setWaitTime(2)
    functions.insert_img(
        context.driver, "financeBookInfo_afterSubmit_" + current_time + ".png")
    def test_1_financeBookInfo_save(self):
        user = init.getUser('销售顾问')
        self.user_login_verify(username=user['username'],password =user['password'],city=user['city'])
        my_client = myClient(self.driver)
        my_client.gotoMyClientList_All(init.getClient('新客户')['lnk_mobile'])
        my_client.setWaitTime(2)
        functions.insert_img(self.driver, current_time + "__myClient_fuzzysearch.png")

        fin_book = finceBookInfo(self.driver)#打开需求书
        fin_book.saveFinancBookInfo()
        my_client.setWaitTime(2)
        functions.insert_img(self.driver, current_time + "__financeBookInfo_afterSave.png")

        #校验需求书是否保存成功
        self.user_login_verify(username=user['username'], password=user['password'], city=user['city'])
        my_client = myClient(self.driver)
        my_client.gotoMyClientList_All(init.getClient('新客户')['lnk_mobile'])
        my_client.setWaitTime(2)
        self.assertEqual(fin_book.verify_finceBookInfo_save_success(),'自动化测试有限公司')
        functions.insert_img(self.driver,current_time+"__myClient_verifyFinBookSave.png")
        my_client.close()
Exemplo n.º 5
0
def step_submitFinceBookInfo(context):
    global fb
    fb = finceBookInfo(context.driver)  # 打开需求书
    fb.submitFinanceBookInfo()
    fb.setWaitTime(2)
    functions.insert_img(context.driver, "financeBookInfo_afterSubmit_"+current_time+".png")