def test_nine_one_times_case(self): """9场对阵,默认倍数1倍""" ha = HomePage(self.driver) hb = RX9C_choosenumber(self.driver) hc = RX9C_ConfirmLottery(self.driver) hc1 = ConfirmLottery(self.driver) hc2 = ArrangeFiveConfirmLottery(self.driver) hl = Login(self.driver) hd = LessPaySucess(self.driver) ha.open() ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作 ha.Moveable_float_close() ha.victory_defeat_14_link() # 点击胜负14场 a = hb.Games_nus(14, 1) ###点击9展示的赛事结果 if a == 1: hb.Confirm_pick() ###点击确认选号 mur = hc1.throw_time_text() ##读取倍数 self.assertEqual('1', mur) mur2 = hc1.lottery_number_text() ##读取注数 self.assertEqual('1', mur2) hc.Submit_station() ####点击提交给站主 hl.login() # 输入账号,密码 hc.Submit_station() # 点击提交给站主 hc1.confirm_and_pay_button() # 点击确认支付() mur1 = hd.assect_pay() ##读取支付状态文本 self.assertEqual('订单提交成功', mur1)
def test_clear_case(self): """验证清楚按钮功能""" ha = HomePage(self.driver) hb = RX9C_choosenumber(self.driver) hc = RX9C_ConfirmLottery(self.driver) hc1 = ConfirmLottery(self.driver) hl = Login(self.driver) hd = LessPaySucess(self.driver) ha.open() ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作 ha.Moveable_float_close() ha.victory_defeat_14_link() # 点击胜负14场 a = hb.Games_nus(14, 1) ###点击9展示的赛事结果 if a == 1: hb.Clear() ###点击清除按钮 hb.Games_nus(14, 1) ###点击9展示的赛事结果 hb.Confirm_pick() ###点击确认选号 mur2 = hc1.lottery_number_text() ##读取注数 self.assertEqual('1', mur2) hc.Submit_station() ####点击提交给站主 # hl.new_user_login_tab() # 点击新登录 hl.login() # 输入账号,密码 hc.Submit_station() # 点击提交给站主 hc1.confirm_and_pay_button() # 点击确认支付() mur1 = hd.assect_pay() ##读取支付状态文本 self.assertEqual('订单提交成功', mur1)