def test_orderdetails_continue_scheme_case(self):
     '''胆拖投注提交订单之后,查看订单详情,点击继续购买该方案,提交订单'''
     hp = HomePage_lexiu(self.driver)
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcl = EleChooseFiveConfirmLottery_lexiu(self.driver)
     od = OrderDetails_lexiu(self.driver)
     l = Login_lexiu(self.driver)
     sos = SubmitOrderSuccess_lexiu(self.driver)
     cl = ConfirmLottery_lexiu(self.driver)
     hp.open()
     hp.Moveable_float_close()
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_lexiu()  # 登录
     hp.homepage_link()  # 点击首页
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn.spread_mode_button()  # 展开玩法
     efcn.mode_choose(22, 16)  # 选择山东11选5胆拖模式任选二玩法
     efcn.dantuo_choose_num(1, 2)  # 选取1个胆码2个拖码
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  ##点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     sos.check_order_details()  # 点击查看订单详情
     od.Scheme()  #点击继续投注该方案
     num1 = efcl.Ele_five_select_number()  # 获取投注确认页的选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  ##点击确认并支付
Exemple #2
0
 def test_machine_choose_one_button_case(self):
     '''投注确认页“机选一注”按钮测试流程'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     ulcn.machine_choose_button()  # 点击机选
     ulcn.machine_choose_one_button()  # 机选一注
     efcn.confirm_number_button()  # 确认选号
     ecfcl = EleChooseFiveConfirmLottery_lexiu(self.driver)
     ecfcl.countdown_text()  # 检查倒计时文案
     ecfcl.machine_choose_one()  # 点击“机选一注”按钮
     check = ecfcl.lottery_chase_throw_text()  # 获取投注注数、追号期数、投注倍数
     self.assertIn("2注1期1倍", check)  ##验证投注注数、投注期号、投注倍数
     ecfcl.submit_order_button()  # 提交订单给站主
     l = Login_lexiu(self.driver)
     l.login_lexiu()  # 登录
     ecfcl.submit_order_button()  # 提交订单给站主
     cl = ConfirmLottery_lexiu(self.driver)
     cl.confirm_and_pay_button()  # 点击确认并支付
     sos = SubmitOrderSuccess_lexiu(self.driver)
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐秀赢球-山东11选5", trade_name)
     sos.check_order_details()  # 点击查看详情
     od = OrderDetails_lexiu(self.driver)
     od.order_details_check()  # 检查订单详情页页面元素
 def test_dantuo_optiops2_intelligent_chase_case(self):  ###mj20171211
     '''胆拖投注,进入智能追号页面,默认追期,提交订单'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ssc_cl = CQSSCConfirmLottery_lexiu(self.driver)
     uncl = ConfirmLottery_lexiu(self.driver)
     efcl = EleChooseFiveConfirmLottery_lexiu(self.driver)
     sos = SubmitOrderSuccess_lexiu(self.driver)
     od = OrderDetails_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.My_lottery_ticket()  #点击我的彩票
     l = Login_lexiu(self.driver)
     l.login_lexiu()  # 点击登录
     hp.Home_page()  #点击首页
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(22, 16)  # 选择山东11选5胆拖模式任选二玩法
     efcn.dantuo_choose_num(1, 2)  # 选取1个胆码2个拖码
     total = efcn.total_buy_text()  # 获取注数文本
     self.assertIn("2", total)  # 检查2注
     efcn.confirm_number_button()  # 点击确认选号
     ssc_cl.intelligently_chase_button()  #点击智能选号
     ssc_cl.submit_button()  #点击智能追号的提交按钮
     uncl.confirm_and_pay_button()  # 点击确认支付
Exemple #4
0
 def test_use_recommand_num_case(self):
     '''使用推荐号码测试'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.current_period()  # 点击“正在开奖中”
     efcn.spread_historical_trend()  # 点击进入历史趋势页
     ht = HistoricalTrend_lexiu(self.driver)
     ht.use_recommend_num_button()  # 点击使用推荐号码
     efcn.confirm_number_button()  # 确认选号
     ecfcl = EleChooseFiveConfirmLottery_lexiu(self.driver)
     ecfcl.countdown_text()  # 检查倒计时文案
     ecfcl.submit_order_button()  # 提交订单给站主
     l = Login_lexiu(self.driver)
     l.login_lexiu()  # 登录
     ecfcl.submit_order_button()  # 提交订单给站主
     cl = ConfirmLottery_lexiu(self.driver)
     cl.confirm_and_pay_button()  # 点击确认并支付
     sos = SubmitOrderSuccess_lexiu(self.driver)
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐秀赢球-山东11选5", trade_name)
     sos.check_order_details()  # 点击查看详情
     od = OrderDetails_lexiu(self.driver)
     od.order_details_check()  # 检查订单详情页页面元素
 def test_dantuo_option4_choose_out_case(self):
     '''山东11选5胆拖玩法,任选四玩法,4个胆码,提示“胆码个数超过限制”流程测试'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(22, 18)  # 选择山东11选5胆拖模式任选四玩法
     efcn.hand_options(4)  # 选取4个胆码
     toast = ulcn.out_of_num()  # 获取toast提示信息
     self.assertEqual("胆码个数超过限制!", toast)
 def test_option14_choose_out_case(self):
     '''山东11选5普通玩法,乐选四玩法,选取5个号码,提示“只支持单式投注”流程测试'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(22, 14)  # 选择山东11选5普通模式乐选四玩法
     efcn.hand_options(5)  # 选取5个号码
     toast = ulcn.out_of_num()  # 获取toast提示信息
     self.assertEqual("只支持单注投注", toast)
 def test_dantuo_option4_choose_2_3_case(self):
     '''山东11选5胆拖玩法,任选四玩法,3个胆码,2个拖码流程测试'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(22, 18)  # 选择山东11选5胆拖模式任选四玩法
     efcn.dantuo_choose_num(3, 2)  # 选取3个胆码2个拖码
     total = efcn.total_buy_text()  # 获取注数文本
     self.assertIn("2", total)  # 检查2注
     efcn.confirm_number_button()  # 点击确认选号
 def test_dantuo_front3_choose_1_3_case(self):
     '''山东11选5胆拖玩法,前三组选玩法,1个胆码,3个拖码流程测试'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(22, 23)  #选择山东11选5胆拖模式前三组选玩法
     sleep(2)
     efcn.dantuo_choose_num(1, 3)  #选取1个胆码3个拖码
     total = efcn.total_buy_text()  # 获取注数文本
     self.assertIn("3", total)  # 检查3注
     efcn.confirm_number_button()  #点击确认选号
 def test_option13_choose_out_case(self):
     '''山东11选5普通玩法,乐选三玩法,三位各选两个号码,提示“只支持单式投注”流程测试'''
     hp = HomePage_lexiu(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_lexiu(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_lexiu(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(22, 13)  # 选择山东11选5普通模式乐选三玩法
     efcn.lexuan_choose(2, 1)  # 第一位选取2个号码
     toast = ulcn.out_of_num()  # 获取toast提示信息
     self.assertEqual("只支持单注投注", toast)
     efcn.lexuan_choose(2, 2)  # 第二位选取2个号码
     toast = ulcn.out_of_num()  # 获取toast提示信息
     self.assertEqual("只支持单注投注", toast)
     js = "window.scroll(0,300)"
     self.driver.execute_script(js)
     efcn.lexuan_choose(2, 3)  # 第三位选取2个号码
     toast = ulcn.out_of_num()  # 获取toast提示信息
     self.assertEqual("只支持单注投注", toast)