Esempio n. 1
0
    def test_(self,casename,device,data):
        ''''''
        roleid = "5dba87241536b40001dbcb90"
        url = self.domain + "/workbench/applications/"+self.applicationId+"/resources/roles/"+roleid+"?device="+device
        responseJson = RequestController.putRequestJson (url=url, headers=self.headers,data=data)
        self.assertEqual (responseJson['msg'], '执行成功')

        #还原
        responseJson2 = RequestController.putRequestJson (url=url, headers=self.headers,data=[])
        self.assertEqual (responseJson2['msg'], '执行成功')
Esempio n. 2
0
    def test_release_processModelIds(self):
        '''用户发布下架流程'''
        processModelIds = 'e60177c4b0f347f49ec15505def5184a'
        xiajia = 'DISRELEASE'  #下架
        fabu = 'RELEASE'  #上架

        #先上架
        url = self.domain+"/workbench/applications/0/process_models/release?processModelIds="+processModelIds+"&processStatusEnum="+fabu
        responseJson = RequestController.putRequestJson(url=url,headers=self.headers,data=None)
        self.assertEqual(responseJson['msg'],'执行成功')

        #下架
        xiajiaurl = self.domain+"/workbench/applications/0/process_models/release?processModelIds="+processModelIds+"&processStatusEnum="+xiajia
        xiajiaresponseJson = RequestController.putRequestJson(url=xiajiaurl,headers=self.headers,data=None)
        self.assertEqual(xiajiaresponseJson['msg'],'执行成功')