fix(环境组): node执行场景使用环境问题
--bug=1008147 --user=lyh 【接口测试】场景定时任务执行没有使用环境组 https://www.tapd.cn/55049933/s/1073453
This commit is contained in:
parent
7ff11ff950
commit
2c29c35e8a
|
@ -85,6 +85,14 @@ public class ApiJmeterFileService {
|
|||
if (item == null) {
|
||||
MSException.throwException("未找到执行场景。");
|
||||
}
|
||||
String envType = item.getEnvironmentType();
|
||||
String envJson = item.getEnvironmentJson();
|
||||
String envGroupId = item.getEnvironmentGroupId();
|
||||
if (StringUtils.equals(envType, EnvironmentType.JSON.name()) && StringUtils.isNotBlank(envJson)) {
|
||||
planEnvMap = JSON.parseObject(envJson, Map.class);
|
||||
} else if (StringUtils.equals(envType, EnvironmentType.GROUP.name()) && StringUtils.isNotBlank(envGroupId)) {
|
||||
planEnvMap = environmentGroupProjectService.getEnvMap(envGroupId);
|
||||
}
|
||||
hashTree = apiAutomationService.generateHashTree(item, reportId, planEnvMap);
|
||||
}
|
||||
return zipFilesToByteArray(remoteTestId, hashTree);
|
||||
|
|
Loading…
Reference in New Issue