Exemplo n.º 1
0
    def setUpClass(self):
        WebDriver.start_browser(self.browesr_name)
        self.driver = WebDriver().get_driver()
        # 后台添加余额宝数据
        ah = AgHome(self.driver)
        Login(self.driver).login_page(self.env_type, self.skin, '后台')
        ah.close_ag_pop()
        ah.swith_mod(self.first, self.second)
        ah.swith_table(self.second)
        self.ac_name = AgYueBao(self.driver).add_yuebao_activ(self.datas[0])

        # 前台
        Login(self.driver).login_page(self.env_type, self.skin, '前端')
    def setUp(self):
        logging.info('启动测试脚本文件: {}.py'.format(self.__module__))
        WebDriver.start_browser(self.browesr_name)
        self.driver = WebDriver().get_driver()
        # 前台造数据
        logging.info("【INFO】登录前台环境准备公司入款数据......")
        Login(self.driver).login_page(self.env_type, self.skin, '前端')
        Us_Center_action(self.driver).to_top_page()
        TopUp(self.driver).random_offline_top()

        # 后台登录
        Login(self.driver).login_page(self.env_type, self.skin, '后台')
        AgHome(self.driver).close_ag_pop()
        # 点击财务管理-公司入款栏目
        AgHome(self.driver).swith_mod(self.first_financial,
                                      self.second_offline)
        # 点击进入公司入款栏目
        AgHome(self.driver).swith_table(self.second_offline)
        # 下面一行用于测试
        #AgOffline(cls.driver).check_is_page()
        # 调用公司入款对象-输入用户名-拿到订单号-唯一标识
        self.order_number = AgOffline(self.driver).get_order_number(
            self.loginfo['user'])
 def tearDown(self):
     WebDriver().driver_quit()
Exemplo n.º 4
0
 def tearDownClass(cls):
     WebDriver().driver_quit()
Exemplo n.º 5
0
 def setUpClass(cls):
     logging.info('启动测试脚本文件: {}.py'.format(cls.__module__))
     WebDriver.start_browser(cls.browesr_name)
     cls.driver = WebDriver().get_driver()
     Login(cls.driver).login_page(cls.env_type, cls.skin, '前端')
Exemplo n.º 6
0
 def tearDown(self) -> None:
     WebDriver().driver_quit()
Exemplo n.º 7
0
 def setUp(self) -> None:
     logging.info('启动测试脚本文件: {}.py'.format(self.__module__))
     WebDriver.start_browser(self.browser_type)
     self.driver = WebDriver().get_driver()
     Login(self.driver).web_login(self.username, self.password)
Exemplo n.º 8
0
 def setUpClass(cls):
     WebDriver.start_browser(cls.browesr_name)
     cls.driver = WebDriver().get_driver()
     Login(cls.driver).login_page(cls.env_type,cls.skin,'前端')
Exemplo n.º 9
0
 def setUpClass(cls):
     WebDriver.start_browser(cls.browesr_name)
     cls.driver = WebDriver().get_driver()
     Login(cls.driver).login_page(cls.env_type, cls.skin, '后台')
     AgHome(cls.driver).close_ag_pop()