def test_fivestar_choose_all_cancel_case(self):
     '''五星直选玩法,选择所有选号,再次点击取消流程'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.five_star()  # 选择五星
     ssc_cn.wanwei_all()
     ssc_cn.qianwei_all()
     ssc_cn.baiwei_all()
     self.driver.execute_script("window.scroll(0,300)")
     ssc_cn.shiwei_all()
     ssc_cn.gewei_all()
     aa = efcn.total_buy_text()
     self.assertIn("100000注 ", aa)
     self.driver.execute_script("window.scroll(0,0)")
     ssc_cn.wanwei_all()
     ssc_cn.qianwei_all()
     ssc_cn.baiwei_all()
     self.driver.execute_script("window.scroll(0,300)")
     ssc_cn.shiwei_all()
     ssc_cn.gewei_all()
     aa = efcn.total_buy_text()
     self.assertIn("请每位至少选择1个号码", aa)
 def test_bigsmall_choose_all_cancel_case(self):
     '''大小单双玩法,个位十位选择所有属性并取消'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.big_little()  # 选择大小单双
     ssc_cn.ds_shiwei_all()  # 十位选择所有号码
     ssc_cn.ds_gewei_all()  # 个位选择所有号码
     aa = efcn.total_buy_text()
     self.assertIn("16注 ", aa)
     ssc_cn.ds_shiwei_all()  # 十位选择取消所有号码
     ssc_cn.ds_gewei_all()  # 个位选择取消所有号码
     aa = efcn.total_buy_text()
     self.assertIn("请至少每位选择1种属性", aa)
 def test_fivestar_choose_one_clear_num(self):
     '''选择一个号码,点击【清除所有选号】,重新选择一个号码,提交订单'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.five_star()  # 选择五星
     ssc_cn.wanwei_random(1)
     ssc_cn.qianwei_random(1)
     ssc_cn.baiwei_random(1)
     self.driver.execute_script("window.scroll(0,300)")
     ssc_cn.shiwei_random(1)
     ssc_cn.gewei_random(1)
     aa = efcn.total_buy_text()
     self.assertIn("1注 ", aa)
     self.driver.execute_script("window.scroll(0,0)")
     ulcn.clear_number()  # 清除所有选号
     cc = efcn.total_buy_text()
     self.assertIn("请每位至少选择1个号码", cc)
     ssc_cn.wanwei_random(2)
     ssc_cn.qianwei_random(2)
     ssc_cn.baiwei_random(2)
     self.driver.execute_script("window.scroll(0,300)")
     ssc_cn.shiwei_random(2)
     ssc_cn.gewei_random(2)
     bb = efcn.total_buy_text()
     self.assertIn("32注 ", bb)
     efcn.confirm_number_button()  # 点击确认选号
     bb = efcl.lottery_chase_throw_text()  # 获取注数倍数
     self.assertIn("32注1期1倍", bb)
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐优炫彩-重庆时时彩", trade_name)
예제 #4
0
 def test_threestar_choose_one_continue_buy_caizhong_case(self):
     '''验证购买成功页【点击继续投注该彩种】,页面跳转至选号页面'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     od = OrderDetails_leyou(self.driver)
     hp.Moveable_float_close()  #点击关闭浮窗
     hp.My_lottery_ticket()  #点击我的彩票
     l.login_leyou()  #点击登录
     hp.homepage_link()  #点击首页
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.cqssc_link()  #点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  #选择模式
     ssc_cn.three_star()  #选择三星
     num1 = ssc_cn.three_star_select(1, 1, 1)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     sos.Continue_buy()  #点击继续投注该彩种
     cc = efcn.total_buy_text()
     self.assertIn("请每位至少选择1个号码", cc, '页面未跳转至选号页面')
 def test_bigsmall_choose_double_case(self):
     '''大小单双玩法,个位十位各选多个属性,确认选号,提交订单'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.big_little()  # 选择大小单双
     ssc_cn.ds_shiwei_all()  # 十位选择所有号码
     ssc_cn.ds_gewei_all()  # 个位选择所有号码
     aa = efcn.total_buy_text()
     self.assertIn("16注 ", aa)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐优炫彩-重庆时时彩", trade_name)
 def test_onestar_machine_five_case(self):
     '''投注确认页,点击【机选5注】,提交订单'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.one_star()  # 选择一星
     ssc_cn.gewei_random(1)  # 选择1个号码
     aa = efcn.total_buy_text()
     self.assertIn("1注", aa)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.machine_choose_five()#点击机选5注
     bb = efcl.lottery_chase_throw_text()  # 获取注数倍数
     self.assertIn("6注1期1倍", bb)
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐优炫彩-重庆时时彩", trade_name)
 def test_dantuo_optiops2_intelligent_chase_case(self):  ###mj20171211
     '''胆拖投注,进入智能追号页面,默认追期,提交订单'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     ssc_cl = CQSSCConfirmLottery_leyou(self.driver)
     uncl = ConfirmLottery_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     od = OrderDetails_leyou(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.My_lottery_ticket()  #点击我的彩票
     l = Login_leyou(self.driver)
     l.login_leyou()  # 点击登录
     hp.Home_page()  #点击首页
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_leyou(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()  # 点击确认支付
 def test_onestar_choose_all_case(self):
     '''一星玩法,选择所有个号码,提交订单测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.one_star()  # 选择一星
     ssc_cn.gewei_all()  # 选择9个号码
     aa = efcn.total_buy_text()
     self.assertIn("10注 ", aa)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐优炫彩-重庆时时彩", trade_name)
예제 #9
0
 def test_threestar_choose_one_case(self):
     '''三星直选玩法,个位十位百位各选一个号码并提交订单流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     od = OrderDetails_leyou(self.driver)
     hp.Moveable_float_close()  #点击关闭浮窗
     hp.My_lottery_ticket()  #点击我的彩票
     l.login_leyou()  #点击登录
     hp.homepage_link()  #点击首页
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.cqssc_link()  #点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  #选择模式
     ssc_cn.three_star()  #选择三星
     num1 = ssc_cn.three_star_select(1, 1, 1)  #百十个位各选一个数字
     aa = efcn.total_buy_text()
     self.assertIn("1注 ", aa)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐优炫彩-重庆时时彩", trade_name)
     sos.check_order_details()  #点击查看订单详情
     num2 = od.bet_number()  #获取页面投注号码
     self.assertIn(num1, num2)
 def test_fivestar_choose_all_case(self):
     '''五星直选玩法,每位各选所有号码'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.five_star()  # 选择五星
     ssc_cn.wanwei_all()
     ssc_cn.qianwei_all()
     ssc_cn.baiwei_all()
     self.driver.execute_script("window.scroll(0,300)")
     ssc_cn.shiwei_all()
     ssc_cn.gewei_all()
     aa = efcn.total_buy_text()
     self.assertIn("100000注 ", aa)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     toast = cl.out_max_pay()
     self.assertEqual("投注金额不能大于100000元", toast)
 def test_fivestar_choose_double_case(self):
     '''五星直选玩法,每位各选多个号码并提交订单流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcl = EleChooseFiveConfirmLottery_leyou(self.driver)
     cl = ConfirmLottery_leyou(self.driver)
     sos = SubmitOrderSuccess_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.five_star()  # 选择五星
     ssc_cn.wanwei_random(2)
     ssc_cn.qianwei_random(2)
     ssc_cn.baiwei_random(2)
     self.driver.execute_script("window.scroll(0,300)")
     ssc_cn.shiwei_random(2)
     ssc_cn.gewei_random(2)
     aa = efcn.total_buy_text()
     self.assertIn("32注 ", aa)
     efcn.confirm_number_button()  # 点击确认选号
     efcl.submit_order_button()  # 点击提交订单给站主
     cl.confirm_and_pay_button()  # 点击确认并支付
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     text = sos.submit_order_success()  # 获取页面“订单提交成功”文本
     self.assertEqual("订单提交成功", text)
     hp.Moveable_float_close()  # 如果出现浮层弹框,关闭
     trade_name = sos.trade_name_text()  # 获取页面商品名称文本
     self.assertIn("商品名称:乐优炫彩-重庆时时彩", trade_name)
예제 #12
0
 def test_twostar_choose_all_cancel_case(self):
     '''二星直选玩法,选择所有选号,再次点击取消流程'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     hp.Moveable_float_close()  #点击关闭浮窗
     hp.My_lottery_ticket()  #点击我的彩票
     l.login_leyou()  #点击登录
     hp.homepage_link()  #点击首页
     hp.cqssc_link()  #点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  #选择模式
     ssc_cn.two_star()  #选择两星
     ssc_cn.shiwei_all()
     ssc_cn.gewei_all()
     aa = efcn.total_buy_text()
     self.assertIn("100注 ", aa)
     ssc_cn.shiwei_all()
     ssc_cn.gewei_all()
     aa = efcn.total_buy_text()
     self.assertIn("请每位至少选择1个号码", aa)
예제 #13
0
 def test_play_instruction_case(self):
     '''在投注选号页面,点击右上角玩法说明,可以打开和关闭'''
     hp = HomePage_leyou(self.driver)
     tD = There_D_choosenumber_leyou(self.driver)
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     hp.open()
     hp.Moveable_float_close()
     hp.gd_11_5_link()  # 点击广东11选5链接
     ulcn.There_clock()  #点击选号页的。。。
     tD.Play_instruction()  #点击玩法说明
     tD.There_D_know()  #点击我知道了
     text1 = efcn.total_buy_text()
     self.assertIn("请至少选择", text1)
 def test_onestar_clear_num_case(self):
     '''一星玩法,选择5号码,并清除,流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.one_star()  # 选择一星
     ssc_cn.gewei_random(5)  #选择5个号码
     aa = efcn.total_buy_text()
     self.assertIn("5注", aa)
     ulcn.clear_number()#清除所有选号
     cc = efcn.total_buy_text()
     self.assertIn("请至少选择1个号码", cc)
     ssc_cn.gewei_random(2)#选择2个号码
     aa = efcn.total_buy_text()
     self.assertIn("2注", aa)
예제 #15
0
 def test_double_cancel_case(self):
     '''验证点击两次号码取消选号,流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.gd_11_5_link()  # 点击广东11选5链接
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(23, 1)  #广东11选5任选二
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     lable1 = efcn.hand_options(11)
     total_buy_text = efcn.total_buy_text()
     self.assertIn("55注 ", total_buy_text)
     efcn.hand_options(11)
     total_buy_text = efcn.total_buy_text()
     self.assertIn("请至少选择", total_buy_text)
     lable2 = efcn.hand_options(2)  #任选两个球
     if lable1 != lable2:
         print("双击取消选号成功")
     else:
         print("双击取消选号失败")
     efcn.confirm_number_button()  #确认选号
 def test_dantuo_option4_choose_2_3_case(self):
     '''山东11选5胆拖玩法,任选四玩法,3个胆码,2个拖码流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_leyou(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()  # 点击确认选号
예제 #17
0
 def test_dantuo_option5_choose_1_5_case(self):
     '''广东11选5胆拖玩法,任选五玩法,1个胆码,5个拖码流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.gd_11_5_link()  # 点击广东11选5链接
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     efcn.countdown_text()  # 检查“距离第xxx期截止:”文案是否存在
     efcn.spread_mode_button()  ##选择展开玩法
     efcn.mode_choose(23, 19)  # 选择广东11选5胆拖模式任选五玩法
     efcn.dantuo_choose_num(1, 5)  # 选取1个胆码5个拖码
     total = efcn.total_buy_text()  # 获取注数文本
     self.assertIn("5", total)  # 检查5注
     efcn.confirm_number_button()  # 点击确认选号
 def test_dantuo_front3_choose_1_3_case(self):
     '''山东11选5胆拖玩法,前三组选玩法,1个胆码,3个拖码流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     ulcn = UnionLottoChooseNumber_leyou(self.driver)
     ######判断是否出现浮层弹框,如果出现浮层点击X,然后执行下一步操作
     hp.Moveable_float_close()
     hp.sd_11_5_link()  # 点击山东11选5链接
     efcn = ElevenFiveChooseNumber_leyou(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_onestar_choose_all_cancel_case(self):
     '''一星玩法,选择所有选号,并取消流程测试'''
     hp = HomePage_leyou(self.driver)
     hp.open()
     l = Login_leyou(self.driver)
     efcn = ElevenFiveChooseNumber_leyou(self.driver)
     hp.Moveable_float_close()  # 点击关闭浮窗
     hp.My_lottery_ticket()  # 点击我的彩票
     l.login_leyou()  # 点击登录
     hp.homepage_link()  # 点击首页
     hp.cqssc_link()  # 点击重庆时时彩链接
     ssc_cn = CQSSC_ChooseNumber_leyou(self.driver)
     ssc_cn.play_mode()  # 选择模式
     ssc_cn.one_star()  # 选择一星
     ssc_cn.gewei_all()  # 选择9个号码
     ssc_cn.gewei_all()#取消选中的9个号码
     aa = efcn.total_buy_text()
     self.assertIn("请至少选择1个号码", aa)