forked from DxvLwRYF/apiAutoTest
update tools/read_config.py.
尝试解决jenkins 流水线任务报错提示TypeNone的问题
This commit is contained in:
parent
c273635fe7
commit
2b6d922293
|
@ -25,8 +25,12 @@ class ReadConfig(object):
|
||||||
|
|
||||||
@logger.catch
|
@logger.catch
|
||||||
def read_response_reg(self):
|
def read_response_reg(self):
|
||||||
get_token = self.data.get("response_reg").get("token")
|
# get_token = self.data.get("response_reg").get("token")
|
||||||
get_resp = self.data.get('response_reg').get('response')
|
# get_resp = self.data.get('response_reg').get('response')
|
||||||
|
# 该写法与上面写法效果类似,随意选择
|
||||||
|
get_token = self.data["response_reg"]["token"]
|
||||||
|
get_resp = self.data['response_reg']['response']
|
||||||
|
|
||||||
logger.info(f'从响应中提取的token表达式: {get_token}')
|
logger.info(f'从响应中提取的token表达式: {get_token}')
|
||||||
logger.info(f'从响应提取的需要校验的表达式: {get_resp}')
|
logger.info(f'从响应提取的需要校验的表达式: {get_resp}')
|
||||||
return get_token, get_resp
|
return get_token, get_resp
|
||||||
|
|
Loading…
Reference in New Issue