fix(接口测试): 脚本步骤没有刷新引用的公共脚本内容
--bug=1046248 --user=陈建星 【项目设置】公共脚本修改,场景内引用脚步未同步更新 https://www.tapd.cn/55049933/s/1578789
This commit is contained in:
parent
eb847d899c
commit
3baf12d0e0
|
@ -1743,7 +1743,9 @@ public class ApiScenarioService extends MoveNodeService {
|
|||
ApiScenarioStep step = apiScenarioStepMapper.selectByPrimaryKey(stepId);
|
||||
StepParser stepParser = StepParserFactory.getStepParser(step.getStepType());
|
||||
Object stepDetail = stepParser.parseDetail(step);
|
||||
if (stepDetail instanceof AbstractMsTestElement msTestElement) {
|
||||
if (stepDetail instanceof MsScriptElement msScriptElement) {
|
||||
apiCommonService.setEnableCommonScriptProcessorInfo(msScriptElement);
|
||||
} else if (stepDetail instanceof AbstractMsTestElement msTestElement) {
|
||||
// 设置关联的文件的最新信息
|
||||
if (isRef(step.getRefType())) {
|
||||
if (isApi(step.getStepType())) {
|
||||
|
@ -1756,10 +1758,7 @@ public class ApiScenarioService extends MoveNodeService {
|
|||
}
|
||||
}
|
||||
apiCommonService.setLinkFileInfo(step.getId(), msTestElement);
|
||||
|
||||
apiCommonService.setEnableCommonScriptProcessorInfo(msTestElement);
|
||||
} else if (stepDetail instanceof MsScriptElement msScriptElement) {
|
||||
apiCommonService.setEnableCommonScriptProcessorInfo(msScriptElement);
|
||||
}
|
||||
return JSON.parseObject(JSON.toJSONString(stepDetail));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue