def setUp(self):
     self.driver = AutomateDriver()
     self.base_url = self.driver.base_url
     self.base_page = BasePage(self.driver, self.base_url)
     self.login_page = LoginPage(self.driver, self.base_url)
     self.user_center = UserCenter(self.driver, self.base_url)
     self.user_center_read_csv = UserCenterReadCsv()
     self.driver.set_window_max()
     self.connect_sql = ConnectSql()
     self.driver.wait(1)
     self.driver.clear_cookies()
     self.driver.wait(1)
Esempio n. 2
0
    def setUp(self):
        self.driver = AutomateDriver()
        self.base_url = self.driver.base_url
        self.base_page = BasePage(self.driver, self.base_url)
        self.login_page = LoginPage(self.driver, self.base_url)
        self.user_center = UserCenter(self.driver, self.base_url)
        self.log_in_page_read_csv = LogInPageReadCsv()
        self.user_center_read_csv = UserCenterReadCsv()
        self.driver.set_window_max()
        self.connect_sql = ConnectSql()
        self.driver.wait(1)
        self.driver.clear_cookies()
        self.driver.wait(1)

        # 打开途强在线首页-登录页
        self.base_page.open_page()
        sleep(1)
        # 登录账号
        self.login_page.test_user_login()