feat(测试用例、接口用例、场景用例): 修复回收站里恢复数据后,没有带上之前的模块信息的Bug;修复环境参数设置不生效的Bug

--bug=1005175 --user=宋天阳
【接口自动化】回收站里恢复场景后,没有带上之前的模块信息
https://www.tapd.cn/55049933/s/1027020
--bug=1005202 --user=宋天阳 【接口自动化】环境参数设置不生效
https://www.tapd.cn/55049933/s/1027053
This commit is contained in:
song-tianyang 2021-07-21 15:10:33 +08:00 committed by 刘瑞斌
parent 77aaec1ea5
commit 3013dcd4ef
2 changed files with 3 additions and 2 deletions

View File

@ -253,7 +253,9 @@ public class MsHTTPSamplerProxy extends MsTestElement {
if (CollectionUtils.isNotEmpty(hashTree)) {
for (MsTestElement el : hashTree) {
el.setEnvironmentId(useEnvironment);
if(this.getEnvironmentId() == null){
el.setEnvironmentId(useEnvironment);
}
el.toHashTree(httpSamplerTree, el.getHashTree(), config);
}
}

View File

@ -52,7 +52,6 @@ import io.metersphere.track.service.TestPlanScenarioCaseService;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.BooleanUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.ExecutorType;
import org.apache.ibatis.session.SqlSession;
import org.apache.ibatis.session.SqlSessionFactory;