refactor(场景自动化): 执行场景前环境检查

This commit is contained in:
shiziyuan9527 2021-05-07 11:21:27 +08:00 committed by 刘瑞斌
parent 4f5387bf8b
commit c2b212f200
1 changed files with 4 additions and 0 deletions

View File

@ -1010,6 +1010,10 @@ public class ApiAutomationService {
Set<String> projectIds = apiScenarioEnv.getProjectIds(); Set<String> projectIds = apiScenarioEnv.getProjectIds();
if (CollectionUtils.isNotEmpty(envMap.keySet())) { if (CollectionUtils.isNotEmpty(envMap.keySet())) {
for (String id : projectIds) { for (String id : projectIds) {
Project project = projectMapper.selectByPrimaryKey(id);
if (project == null) {
id = apiScenarioWithBLOBs.getProjectId();
}
String s = envMap.get(id); String s = envMap.get(id);
if (StringUtils.isBlank(s)) { if (StringUtils.isBlank(s)) {
isEnv = false; isEnv = false;