Example #1
0
 def test_UnionLotto_Machine_choose_one_case(self):
     '''机选一注测试'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  #点击双色球链接
     ####选择机选一注并确认选号####
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.machine_choose_button()  #点击机选
     ulcn.machine_choose_one_button()  #机选一注
     ulcn.Confirm_button()  #确认选号
     ######进入提交订单页面######
     cl = ConfirmLottery_lelun(self.driver)
     lottery_number_text = cl.lottery_number_text()
     self.assertIn("1", lottery_number_text)  #检查投注注数为1注
     cl.submit_order_to_station_owner_button()  #点击“提交订单给站主”按钮
     #####用户登录######
     l = Login_lelun(self.driver)
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  #点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  #点击“确认并支付”按钮
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     hp.Moveable_float_close()
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text)
     trade_text = sos.trade_name_text()  #获取商品名称
     self.assertIn("商品名称:乐仑炫彩-双色球", trade_text)  #检查商品名称正确
 def test_UnionLotto_CheckOrderDetails_case(self):
     '''查看订单详情页测试'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     # 选号
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.u_red_label6()  # 任意选择6个红球
     ulcn.u_bule_label1()  # 任意选择1个蓝球
     ulcn.Confirm_button()  # 点击确认选号按钮
     cl = ConfirmLottery_lelun(self.driver)
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     #####用户登录######
     l = Login_lelun(self.driver)
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  # 点击“确认并支付”按钮
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
     sos.check_order_details()  #点击“查看订单详情”
     od = OrderDetails_lelun(self.driver)
     od.order_status()  #获取订单状态
     od.number_bet()  #获取投注号码
     od.official_open_time()  #获取开奖时间
     od.order_number()  #获取订单编号
 def test_after_shortfall_case(self):
     '''验证差额支付,复式号码流程'''
     ###点击进入双色球选号页面###
     ha = HomePage_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc= ConfirmLottery_lelun(self.driver)
     hd = PaymetMode_lelun(self.driver)
     he = BaofooPayment_lelun(self.driver)
     hf = ChooseBank_lelun(self.driver)
     hf1 = ConfirmPay_lelun(self.driver)
     hf2= LessPaySucess_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()#点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1_too()  # 任意选择2个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     hl.login_nomoney_lelun()#点击登录
     hc.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     hc.confirm_and_pay_button()  # 点击“确认并支付”按钮
     mur=hd.Top_up()##获取充值成功文本
     self.assertEqual('充值',mur)
 def test_UnionLotto_Continue_buy_scheme(self):
     """验证继续购买该方案"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hc1 = PaintBallChooseNumber_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     he = OrderDetails_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.Select_number()
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('1', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
     #hl.new_user_login_tab()  # 点击新登录
     hl.login_lelun()  # 输入账号,密码
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     hc.confirm_and_pay_button()  # 点击确认支付
     hd.check_order_details()  ##点击查看订单详情
     mur4 = he.order_status()
     self.assertEqual('待出票', mur4)
     he.Scheme()  #点击继续购买该方案
     mur2 = hc.confirm_num_page_text()
     self.assertEqual('提交订单给站主', mur2)
    def test_UnionLotto_Hand_choose_case(self):
        """双色球手选6个红球1个蓝球购买流程测试"""
        ###点击进入双色球选号页面###
        hp = HomePage_lelun(self.driver)
        hp.open()
        ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
        hp.Moveable_float_close()
        hp.UnionLotto_link()  #点击双色球链接

        #选号
        ulcn = UnionLottoChooseNumber_lelun(self.driver)
        ulcn.u_red_label6()  #任意选择6个红球
        ulcn.u_bule_label1()  #任意选择1个蓝球
        ulcn.Confirm_button()  #点击确认选号按钮
        cl = ConfirmLottery_lelun(self.driver)
        cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
        #####用户登录######
        l = Login_lelun(self.driver)
        l.login_lelun()
        cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
        cl.confirm_and_pay_button()  # 点击“确认并支付”按钮
        '''断言验证提交订单成功'''
        sos = SubmitOrderSuccess_lelun(self.driver)
        hp.Moveable_float_close()  # 关闭悬浮窗口
        text = sos.submit_order_success()
        self.assertEqual("订单提交成功", text, "提交订单失败")
 def test_UnionLotto_history_recommend_many(self):
     """历史走势,手动选择,复式"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     he = OrderDetails_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.There_clock()  ##点击右上角。。。
     hb.History_movements()  ##点击历史走势
     hb.Red_movements()  ##点击红球走势
     hb.History_red(7)  ##点击7个数字
     hb.Bule_movements()  #点击蓝球走势
     hb.History_bule(2)  ###点击1个蓝球
     hb.Recommended_number()  ###点击使用已选号码
     hb.Confirm_button()  # 确认选号
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('7', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
 def test_UnionLotto_Hand_r19_case(self):
     '''双色球选取19个红球,第19个红球提示“红球不能超过18个”测试'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.u_red_label19()  # 选取19个红球
     text = ulcn.out_of_num()  #获取超过18个红球时的toast提示信息
     self.assertIn("红球不能超过18个", text)
     ulcn.u_bule_label1()  #选取1个蓝球
     ulcn.Confirm_button()  # 点击确认选号按钮
     cl = ConfirmLottery_lelun(self.driver)
     cl.submit_order_to_station_owner_button()  # 提交订单给站主
     l = Login_lelun(self.driver)  #####用户登录######
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  # 点击“确认并支付”按钮
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     hp.Moveable_float_close()  # 关闭悬浮窗口
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
 def test_UnionLotto_Hand_r18b16_case(self):
     '''双色球选取18个红球,16个蓝球提示“投注金额不能大于100000元”测试'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.u_red_label18()  # 选取18个红球
     ulcn.u_bule_label16()  #选取16个蓝球
     ulcn.Confirm_button()  # 点击确认选号按钮
     cl = ConfirmLottery_lelun(self.driver)
     cl.submit_order_to_station_owner_button()  # 提交订单给站主
     l = Login_lelun(self.driver)  #####用户登录######
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  #点击确认并支付按钮
     text = cl.out_max_pay()  #获取超额提示信息文本
     self.assertIn("投注金额不能大于100000元", text)
     cl.re_selection_num()  #点击重新选号链接
     ulcn.u_bule_label16()  #取消选中的16个蓝球
     ulcn.u_bule_label1()  #选取1个蓝球
     ulcn.Confirm_button()  #点击确认选号
     cl.submit_order_to_station_owner_button()  #提交订单给站主
     cl.confirm_and_pay_button()  #确认支付
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     hp.Moveable_float_close()  # 关闭悬浮窗口
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
 def test_UnionLotto_DanTuo_many_case(self):
     """增加倍数和期数"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.DanTuo_mode()  # 选择胆拖模式
     hb.u_red_five_two()  # 红球选取5个胆码2个拖码
     hb.u_bule_one()  # 选取一个蓝球
     hb.Confirm_button()  # 确认选号
     hc.throw_times_input(13)
     hc.chase_ticket_button()  # 点击追xx期
     hc.chase_ticket_button_twenty()  # 点击追20期
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('2', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('13', nu)
     chase_time_text = hc.chase_time_text()  # 获取追号期数
     self.assertIn("20", chase_time_text)  # 检查追号期数为20期
     hc.submit_order_to_station_owner_button()
 def test_one_note_five_double_ten_period_shortfall_case(self):
     '''手选一注,1注单式号码,修改倍数5,修改期数10,差额支付流程'''
     ###点击进入双色球选号页面###
     ha = HomePage_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc= ConfirmLottery_lelun(self.driver)
     hd = PaymetMode_lelun(self.driver)
     he = BaofooPayment_lelun(self.driver)
     hf = ChooseBank_lelun(self.driver)
     hf1 = ConfirmPay_lelun(self.driver)
     hf2= LessPaySucess_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()#点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.chase_ticket_input("10")#输入追10期
     hc.throw_times_input("5")#输入投注倍数为5倍
     hc.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     hl.login_nomoney_lelun()#点击登录
     hc.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     hc.confirm_and_pay_button()  # 点击“确认并支付”按钮
     mur = hd.Top_up()  ##获取充值成功文本
     self.assertEqual('充值', mur)
Example #11
0
 def test_UnionLotto_history_recommend(self):
     """使用推荐号码投注(一注一倍)"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     he = OrderDetails_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.There_clock()  ##点击右上角。。。
     hb.History_movements()  ##点击历史走势
     mur = hb.Recommended_nu()  #读取推荐号码
     hb.Recommended_number()  #点击使用推荐号码
     hb.Confirm_button()  # 确认选号
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     #hl.new_user_login_tab()  # 点击新登录
     hl.login_lelun()  # 输入账号,密码
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     hc.confirm_and_pay_button()  # 点击确认支付
     hd.check_order_details()  ##点击查看订单详情
     mur1 = he.Betting_number()  ##读取显示的投注号码
     self.assertEqual(mur, mur1)
 def test_unionlotto_dantuo_continue_case(self):
     """胆拖选号页面,选择1注号码,在投注确认页面,继续选1注"""
     ha = HomePage_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hd = PaymetMode_lelun(self.driver)
     he = BaofooPayment_lelun(self.driver)
     hf = ChooseBank_lelun(self.driver)
     hf1 = ConfirmPay_lelun(self.driver)
     hf2 = LessPaySucess_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.DanTuo_mode()  # 选择胆拖模式
     hb.u_red_five_two()  # 红球选取5个胆码2个拖码
     hb.u_bule_one()  # 选取一个蓝球
     hb.Confirm_button()  # 确认选号
     hc.continue_choose_num_button()  ##继续选号
     hb.u_red_five_two()  # 红球选取5个胆码2个拖码
     hb.u_bule_one()  # 选取一个蓝球
     hb.Confirm_button()  # 确认选号
     hc.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     hl.login_nomoney_lelun()  # 点击登录
     hc.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     hc.confirm_and_pay_button()  # 点击“确认并支付”按钮
     mur = hd.Top_up()  ##获取充值成功文本
     self.assertEqual('充值', mur)
Example #13
0
 def test_UnionLotto_Machine_continue_choose_button(self):
     '''机选一注“继续选号”按钮测试'''
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ####选择机选一注并确认选号####
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.machine_choose_button()  # 点击机选
     ulcn.machine_choose_one_button()  # 机选1注
     ulcn.Confirm_button()  # 确认选号
     cl = ConfirmLottery_lelun(self.driver)
     cl.continue_choose_num_button()  #点击“继续选号”按钮
     ulcn.machine_choose_button()  # 点击机选
     ulcn.machine_choose_one_button()  # 机选1注
     ulcn.Confirm_button()  # 确认选号
     lottery_number_text = cl.lottery_number_text()
     self.assertIn("2", lottery_number_text)
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     #####用户登录######
     l = Login_lelun(self.driver)
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  #确认支付
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     hp.Moveable_float_close()  #关闭弹窗
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
     trade_text = sos.trade_name_text()  # 获取商品名称
     self.assertIn("商品名称:乐仑炫彩-双色球", trade_text)  # 检查商品名称正确
     sos.check_order_details()  #查看订单详情
     od = OrderDetails_lelun(self.driver)
     od.order_details_check()  #检查订单详情页
 def test_UnionLotto_Continue_buy(self):
     """验证继续投注该彩种"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hc1 = PaintBallChooseNumber_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     hf = SubmitOrderSuccess_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('1', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
     #hl.new_user_login_tab()  # 点击新登录
     hl.login_lelun()  # 输入账号,密码
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     hc.confirm_and_pay_button()  # 点击确认支付
     hd.Continue_buy()  ##点击继续购买该彩种
     mur1 = hc1.Play_fb()
     self.assertEqual('玩\n法', mur1)
     hb.machine_choose_button()  # 点击机选
     hb.machine_choose_one_button()  # 机选一注
     hb.Confirm_button()  # 确认选号
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     hc.confirm_and_pay_button()  # 点击确认支付
     text1 = hf.submit_order_success()  # 获取提交订单成功文本
     self.assertEqual('订单提交成功', text1)
Example #15
0
 def test_UnionLotto_history_recommend_many(self):
     """使用推荐号码投注(多注注多倍)"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     he = OrderDetails_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.There_clock()  ##点击右上角。。。
     hb.History_movements()  ##点击历史走势
     hb.Recommended_nu()  #读取推荐号码
     hb.Recommended_number()  #点击使用推荐号码
     hb.Select_bule()  ##点击一个蓝球
     hb.Confirm_button()  # 确认选号
     mur2 = hc.Select_number()  ##读取投注号码
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('2', mur)  ##断言
     hc.throw_times_input(13)  ###点击倍数输入功能
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('13', nu)
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     #hl.new_user_login_tab()  # 点击新登录
     hl.login_lelun()  # 输入账号,密码
     hc.submit_order_to_station_owner_button()  # 点击提交给站主
     hc.confirm_and_pay_button()  # 点击确认支付
     hd.check_order_details()  ##点击查看订单详情
     mur1 = he.Betting_nu()  ##读取显示的投注号码
     self.assertEqual(mur2, mur1)
Example #16
0
 def test_UnionLotto_Machine_choose_five_delete_all_case(self):
     '''机选五注全部删除并确定流程测试'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ####选择机选一注并确认选号####
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.machine_choose_button()  # 点击机选
     ulcn.machine_choose_five_button()  # 机选5注
     ######进入提交订单页面######
     cl = ConfirmLottery_lelun(self.driver)
     chase = cl.chase_time_text()  # 获取追号期数
     times = cl.throw_time_text()  # 获取输入的投注倍数
     lottery_num = cl.lottery_number_text()  #获取投注注数
     self.assertEqual("5", lottery_num)  #检查投注的注数为5注
     self.assertEqual("1", chase)  # 检查追号期数1期
     self.assertEqual("1", times)  # 检查投注倍数1倍
     cl.delete_all_num_button()  #点击删除所有选号
     cl.confirm_delete_button()  #点击确认删除
     ulcn.machine_choose_button()  #点击机选按钮
     ulcn.machine_choose_one_button()  #点击机选1注
     ulcn.Confirm_button()  #确认选号
     chase = cl.chase_time_text()  # 获取追号期数
     times = cl.throw_time_text()  # 获取输入的投注倍数
     lottery_num = cl.lottery_number_text()  # 获取投注注数
     self.assertEqual("1", lottery_num)  # 检查投注的注数为1注
     self.assertEqual("1", chase)  # 检查追号期数1期
     self.assertEqual("1", times)  # 检查投注倍数1倍
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     #####用户登录######
     l = Login_lelun(self.driver)
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  # 点击“确认并支付”按钮
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
     trade_text = sos.trade_name_text()  # 获取商品名称
     self.assertIn("商品名称:乐仑炫彩-双色球", trade_text)  # 检查商品名称正确
     sos.check_order_details()  # 查看订单详情
     od = OrderDetails_lelun(self.driver)
     od.order_details_check()  # 检查订单详情页
 def test_UnionLotto_unitary_del_X(self):
     """左边X按钮,能够删除所选号码"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hc1 = PaintBallChooseNumber_lelun(self.driver)
     hd = PaintBallConfirm_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.Del_x()  ##点击左侧X按钮
     mur1 = hc1.Play_fb()
     self.assertEqual('玩\n法', mur1)
 def test_UnionLotto_after_many_note_many_multiple(self):
     """复式,多注多倍"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label18()  # 任意选择18个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.throw_times_input(13)
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('18564', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('13', nu)
     hc.submit_order_to_station_owner_button()
 def test_Direct_add_Del_all_nu_ok_case(self):
     """验证确认投注页面,点击删除选号图标功能"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hc1 = PaintBallChooseNumber_lelun(self.driver)
     hd = PaintBallConfirm_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.delete_all_num_button()  ###点击清除所有选号
     hc.confirm_delete_button()  # 点击确定
     mur = hc1.Play_fb()
     self.assertEqual('玩\n法', mur)
 def test_UnionLotto_risk(self):
     """验证购彩风险"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.Risk()  ##点击用户协议
     hc.Risk_know()  ##点击用户协议我知道了
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('1', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
Example #21
0
 def test_UnionLotto_machine_one_after(self):
     """机选一注之后,新增选号,变为复式"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.machine_choose_button()  # 点击机选
     hb.machine_choose_one_button()  # 机选一注
     hb.Confirm_button()  # 确认选号
     hc.re_selection_num()
     hb.Select_bule()  ###添加一个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('2', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
 def test_UnionLotto_DanTuo_5_2_16_case(self):
     """红球胆码5个 ,红球拖码 2个,蓝球16个"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.DanTuo_mode()  # 选择胆拖模式
     hb.u_red_five_two()  #选择5个胆码2个拖码
     hb.u_bule_sixteen()  ##选择16个蓝球
     hb.Confirm_button()  # 确认选号
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('32', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
 def test_UnionLotto_many_pause(self):
     """多期机选"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hl = Login_lelun(self.driver)
     hd = SubmitOrderSuccess_lelun(self.driver)
     he = OrderDetails_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.My_lottery_ticket()  ##点击我的彩票
     hl.login_lelun()  ##登录
     ha.Home_page()  ##点击首页
     ha.UnionLotto_link()  # 点击双色球链接
     hb.There_clock()  ##点击右上角。。。
     hb.Many_pause()  #点击多期机选
     hb.Many_pause_nu()  ##点击期号
     hb.Many_pause_confirm()  ##点击提交
     hc.confirm_and_pay_button()  # 点击确认支付
 def test_less_payment_shortfall_case(self):
     '''验证差额支付流程'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     l=Login_lelun(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()#点击双色球链接
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.u_red_label6()  # 任意选择6个红球
     ulcn.u_bule_label1()  # 任意选择1个蓝球
     ulcn.Confirm_button()  # 点击确认选号按钮
     cl = ConfirmLottery_lelun(self.driver)
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     l.login_nomoney_lelun()#点击登录
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  # 点击“确认并支付”按钮
     pm = PaymetMode_lelun(self.driver)
     mur = pm.Top_up()  ##获取充值成功文本
     self.assertEqual('充值', mur)
Example #25
0
 def test_UnionLotto_assemblage_after(self):
     """多注(复式、单式组合)选号"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.machine_choose_button()  # 点击机选
     hb.machine_choose_one_button()  # 机选一注
     hb.Confirm_button()  # 确认选号
     hc.continue_choose_num_button()  ##继续选号
     hb.u_red_label18()  # 任意选择18个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('18565', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()
Example #26
0
 def test_UnionLotto_Continue_pick(self):
     """继续选号添加复式选号"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.continue_choose_num_button()  ##继续选号
     hb.u_red_label18()  # 任意选择18个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('18565', mur)
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()  ##点击提交给站主
Example #27
0
 def test_UnionLotto_Machine_input_three_times_add_case(self):
     '''输入投3倍,再点击+流程测试'''
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ####选择机选一注并确认选号####
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.machine_choose_button()  # 点击机选
     ulcn.machine_choose_one_button()  # 机选1注
     ulcn.Confirm_button()  # 确认选号
     cl = ConfirmLottery_lelun(self.driver)
     cl.throw_times_input("3")  #输入投注倍数为3倍
     lottery_number_text = cl.lottery_number_text()  # 获取投注注数文本
     self.assertIn("1", lottery_number_text)  # 检查投注注数为1注
     throw_times = cl.throw_time_text()  #获取投注倍数定位
     self.assertIn("3", throw_times)  #检查投注倍数为3倍
     cl.u_throw_times_button_add()  #点击+
     lottery_number_text = cl.lottery_number_text()  # 获取投注注数文本
     self.assertIn("1", lottery_number_text)  # 检查投注注数为1注
     throw_times = cl.throw_time_text()  # 获取投注倍数定位
     self.assertIn("4", throw_times)  # 检查投注倍数为4倍
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     #####用户登录######
     l = Login_lelun(self.driver)
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.confirm_and_pay_button()  # 确认支付
     '''断言验证提交订单成功'''
     sos = SubmitOrderSuccess_lelun(self.driver)
     hp.Moveable_float_close()  # 关闭弹窗
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
     trade_text = sos.trade_name_text()  # 获取商品名称
     self.assertIn("商品名称:乐仑炫彩-双色球", trade_text)  # 检查商品名称正确
     sos.check_order_details()  # 查看订单详情
     od = OrderDetails_lelun(self.driver)
     od.order_details_check()  # 检查订单详情页
Example #28
0
 def test_UnionLotton_Machine_cancel_pay(self):
     '''机选一注取消支付测试'''
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ####选择机选一注并确认选号####
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.machine_choose_button()  # 点击机选
     ulcn.machine_choose_one_button()  # 机选1注
     ulcn.Confirm_button()  # 确认选号
     cl = ConfirmLottery_lelun(self.driver)
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     #####用户登录######
     l = Login_lelun(self.driver)
     l.login_lelun()
     cl.submit_order_to_station_owner_button()  # 点击“提交订单给站主”按钮
     cl.cancel_pay_button()  #点击取消支付x按钮
     '''断言验证取消支付成功'''
     text = cl.confirm_num_page_text()
     self.assertEqual("提交订单给站主", text)
     print("我已放弃删除,回到了" + text + "页")
 def test_UnionLotto_DanTuo_6_19_1_case(self):
     '''手选6个胆码19个拖码,1个蓝球的流程测试'''
     ###点击进入双色球选号页面###
     hp = HomePage_lelun(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.UnionLotto_link()  # 点击双色球链接
     ulcn = UnionLottoChooseNumber_lelun(self.driver)
     ulcn.DanTuo_mode()  # 选择胆拖模式
     ulcn.u_red_six_nineteen()  # 红球选取6个胆码19个拖码
     ulcn.u_bule_one()  # 选取1个蓝球
     ulcn.Confirm_button()  # 点击确认选号
     cl = ConfirmLottery_lelun(self.driver)
     cl.submit_order_to_station_owner_button()  # 点击提交订单给站主
     l = Login_lelun(self.driver)
     l.login_lelun()  # 点击登录
     cl.submit_order_to_station_owner_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     sos = SubmitOrderSuccess_lelun(self.driver)
     hp.Moveable_float_close()  # 关闭悬浮窗口
     text = sos.submit_order_success()
     self.assertEqual("订单提交成功", text, "提交订单失败")
 def test_UnionLotto_unitary_many_note_del_X(self):
     """左边X按钮,能够删除所选号码"""
     ha = HomePage_lelun(self.driver)
     hb = UnionLottoChooseNumber_lelun(self.driver)
     hc = ConfirmLottery_lelun(self.driver)
     hd = PaintBallConfirm_lelun(self.driver)
     ha.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     ha.Moveable_float_close()
     ha.UnionLotto_link()  # 点击双色球链接
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.continue_choose_num_button()  ##继续选号
     hb.u_red_label6()  # 任意选择6个红球
     hb.u_bule_label1()  # 任意选择1个蓝球
     hb.Confirm_button()  # 点击确认选号按钮
     hc.Del_x()  ##点击左侧X按钮
     mur = hc.lottery_number_text()  # 读取注数
     self.assertEqual('1', mur)  ##断言
     nu = hc.throw_time_text()  ###倍数
     self.assertEqual('1', nu)
     hc.submit_order_to_station_owner_button()