Skip to content

Commit

Permalink
fix(接口测试): 修复随机变量获取不到值问题
Browse files Browse the repository at this point in the history
--bug=1021346 --user=赵勇 【接口测试】github#21012,2.5版本接口自动化场景变量格式化输出随机变量引用不到值 https://www.tapd.cn/55049933/s/1320661
  • Loading branch information
fit2-zhao committed Dec 29, 2022
1 parent 434dcf8 commit 8e5455a
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@ public void toHashTree(HashTree tree, List<MsTestElement> hashTree, MsParameter
scenarioTree.add(valueSupposeMock);
}
}
if (BooleanUtils.isTrue(this.variableEnable) || BooleanUtils.isTrue(this.mixEnable)) {
if ((this.variableEnable == null && this.mixEnable == null)
|| BooleanUtils.isTrue(this.variableEnable) || BooleanUtils.isTrue(this.mixEnable)) {
ElementUtil.addCsvDataSet(scenarioTree, variables, this.isEnvironmentEnable() ? newConfig : config, "shareMode.group");
ElementUtil.addCounter(scenarioTree, variables);
ElementUtil.addRandom(scenarioTree, variables);
Expand Down

0 comments on commit 8e5455a

Please sign in to comment.