Exemplo n.º 1
0
 def setUpClass(cls):
     Log.info('TestUserLogin START BB端')
     # cls.lc = LoadConfig()
     # cls.domain = cls.lc.get_domain()
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=2)
Exemplo n.º 2
0
 def setUpClass(cls):
     Log.info('TestDownloadTaskHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.df = DownloadFile(node=cls.node)
Exemplo n.º 3
0
 def setUpClass(cls):
     Log.info('TestVCFStartHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.cal_vcf = CalVcf(node=cls.node)
Exemplo n.º 4
0
 def setUpClass(cls):
     Log.info('TestGetErrorResultBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.h_g = HistoryGWAS(node=cls.node)
Exemplo n.º 5
0
 def setUpClass(cls):
     Log.info('TestGetGenResultHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.h_t = HistoryTest(node=cls.node)
Exemplo n.º 6
0
 def setUpClass(cls):
     Log.info('TestQueryInStatusBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.ui = UserInfo(node=cls.node)
Exemplo n.º 7
0
 def setUpClass(cls):
     Log.info('TestGwasStartBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.cal_gwas = CalGwas(node=cls.node)
Exemplo n.º 8
0
 def setUpClass(cls):
     Log.info('TestDownloadPublicTaskBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.df = DownloadFile(node=cls.node)
Exemplo n.º 9
0
 def setUpClass(cls):
     Log.info('TestGetListByAcceptHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.cal_get = CalGet(node=cls.node)
Exemplo n.º 10
0
 def setUpClass(cls):
     Log.info('TestQueryUpdateFlagHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.cancel_task = CancelTask(node=cls.node)
Exemplo n.º 11
0
 def setUpClass(cls):
     Log.info('TestCancelTaskBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.cancel_task = CancelTask(node=cls.node)
Exemplo n.º 12
0
 def setUpClass(cls):
     Log.info('TestGetServerBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.cal_get = CalGet(node=cls.node)
Exemplo n.º 13
0
 def setUpClass(cls):
     Log.info('TestGetListBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.h_t = HistoryTest(node=cls.node)
Exemplo n.º 14
0
 def setUpClass(cls):
     Log.info('TestComputeMulBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.comp_vcf = ComputeVcf(node=cls.node)
Exemplo n.º 15
0
 def setUpClass(cls):
     Log.info('TestUpLoadFileHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.fh = FileHandle(node=cls.node)
Exemplo n.º 16
0
 def setUpClass(cls):
     Log.info('TestComputeVcfHK START HK端')
     cls.node = 1
     # 计算类型  vcf;1
     cls.calType = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.comp_vcf = ComputeVcf(node=cls.node)
Exemplo n.º 17
0
 def setUpClass(cls):
     Log.info('TestComputeGwasBB START BB端')
     cls.node = 2
     # 计算类型  gwas;3
     cls.calType = 3
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.comp_gwas = ComputeGwas(node=cls.node)
Exemplo n.º 18
0
 def setUpClass(cls):
     Log.info('TestComputeGenHK START HK端')
     cls.node = 1
     # 计算类型  gen;2
     cls.calType = 2
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.comp_gen = ComputeGen(node=cls.node)
Exemplo n.º 19
0
 def setUpClass(cls):
     Log.info('TestUpdateUserHK START HK端')
     cls.node = 1
     cls.dh = DataHandle()
     # 香港端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.ui = UserInfo(node=cls.node)
     # cls.url = cls.lc.get_domain() + cls.dh.get_path(1)
     # auto登录cookie
     cls.AUTO_cookies = cls.ui.modify_cookies(data_id=3001, node=cls.node)
Exemplo n.º 20
0
 def setUpClass(cls):
     Log.info('TestDownloadLogFileBB START BB端')
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.df = DownloadFile(node=cls.node)
     cls.ui = UserInfo(node=cls.node)
     # auto登录cookie
     cls.AUTO_cookies = cls.ui.modify_cookies(data_id=3001, node=cls.node)
Exemplo n.º 21
0
 def setUpClass(cls):
     Log.info('TestUserInfoBB START BB端')
     # cls.lc = LoadConfig()
     # cls.domain = cls.lc.get_domain()
     cls.node = 2
     cls.dh = DataHandle()
     # 布里端
     cls.L = Login(node=cls.node)
     cls.admin_cookies = cls.L.get_cookie()
     cls.ui = UserInfo(node=cls.node)
     # cls.url = cls.lc.get_domain() + cls.dh.get_path(1)
     # auto登录cookie
     cls.modify_cookie = cls.ui.modify_cookies(data_id=3001, node=cls.node)
Exemplo n.º 22
0
        list2.append(data_res['top'])
        # list1.append(data_database['logicType'])
        # list2.append(data_res['logicType'])
        Log.info('compare data is database :{}'.format(list1))
        Log.info('compare data is interface :{}'.format(list2))
        if list1 == list2:
            return True
        return False

    @staticmethod
    def get_list_by_accept_check(res):
        code = '00000'
        message = '成功'
        if res['code'] == code and res['message'] == message:
            Log.info('actual res check is 1 ,success !')
            return 1
        Log.error('请求返回有误!{}'.format(res))
        return 0


if __name__ == '__main__':
    Log.debug('*' * 50)
    cv = CalGet(node=1)
    ck = Login(node=1)
    cookie = ck.get_cookie()
    # cookie =None
    para_id = 20
    data_id = 20001
    cv.base_get_server(para_id, data_id, cookie)
    Log.debug('*' * 50)
Exemplo n.º 23
0
 def modify_cookies(self, data_id, node):
     """获取automation登录后cookie"""
     self.before_modify_check()
     L = Login(node=node)
     cookie_modify = L.get_cookie(data_id=data_id)
     return cookie_modify
Exemplo n.º 24
0
    @staticmethod
    def upload_check(res):
        """1 成功 0 失败"""
        code = '00000'
        message = '成功'
        if res["code"] == code and res['message'] == message \
                and isinstance(res['data'], int):
            Log.debug('actual res check is 1')
            return 1
        else:
            Log.debug('actual res check is 0')
            return 0
        pass


if __name__ == '__main__':
    fh = FileHandle(2, 1)
    # name = 'case_part1.txt'
    p_id = 10
    d_id = 10001
    cookies = Login(node=2, path_id=1).get_cookie()
    # cookies = None
    fh.base_upload(para_id=p_id,
                   data_id=d_id,
                   cookies=cookies,
                   isChange=0,
                   noFile=0)
    # print(fh.change_name(name))
    # print(fh.gene_file(name))