fix(接口测试): 修复场景执行单步骤时提示csv不存在的缺陷
--bug=1025964 --user=王孝刚 【接口测试】新建场景-添加csv场景变量-单步骤调试失败引用csv文件失败 https://www.tapd.cn/55049933/s/1368703
This commit is contained in:
parent
d8bc95e2e9
commit
306c46d22d
|
@ -172,14 +172,6 @@
|
|||
</div>
|
||||
</template>
|
||||
</api-base-component>
|
||||
<ms-run
|
||||
:debug="true"
|
||||
:reportId="reportId"
|
||||
:run-data="runData"
|
||||
:env-map="environmentMap"
|
||||
@runRefresh="runRefresh"
|
||||
@errorRefresh="errorRefresh"
|
||||
ref="runTest" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
@ -237,7 +229,6 @@ export default {
|
|||
MsDubboBasisParameters: () => import('../../../definition/components/request/dubbo/BasisParameters'),
|
||||
MsApiRequestForm: () => import('../../../definition/components/request/http/ApiHttpRequestForm'),
|
||||
MsRequestResultTail: () => import('../../../definition/components/response/RequestResultTail'),
|
||||
MsRun: () => import('../../../definition/components/Run'),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
|
@ -480,7 +471,7 @@ export default {
|
|||
// 场景变量
|
||||
let variables = [];
|
||||
if (this.currentScenario && this.currentScenario.variables) {
|
||||
variables = JSON.parse(JSON.stringify(this.currentScenario.variables));
|
||||
variables = this.currentScenario.variables;
|
||||
}
|
||||
let debugData = {
|
||||
id: this.currentScenario.id,
|
||||
|
@ -518,6 +509,9 @@ export default {
|
|||
this.request.result = undefined;
|
||||
/*触发执行操作*/
|
||||
this.reportId = getUUID();
|
||||
debugData.hashTree = [this.request];
|
||||
debugData.stepScenario = true;
|
||||
this.$emit('runScenario', debugData);
|
||||
}
|
||||
});
|
||||
},
|
||||
|
|
|
@ -193,7 +193,7 @@ export default {
|
|||
}
|
||||
this.scenario.run = true;
|
||||
let runScenario = JSON.parse(JSON.stringify(this.scenario));
|
||||
let variables = JSON.parse(JSON.stringify(this.currentScenario.variables));
|
||||
let variables = this.currentScenario.variables;
|
||||
|
||||
// 合并自身依赖场景变量
|
||||
if (runScenario && runScenario.variableEnable && runScenario.variables) {
|
||||
|
|
|
@ -73,7 +73,7 @@ export default {
|
|||
open(objStr) {
|
||||
this.data = {};
|
||||
try {
|
||||
let stringedJSON = objStr.replace(/:\s*(?!.*\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}\+\d{2}:\d{2})\s([-+Ee0-9.]+)/g, ': "$1"');
|
||||
let stringedJSON = objStr.replace(/(?<=[:\[,])\s*(-?\d+(\.\d+)?)(?=\s*([,\]}]))/g, '"$1"');
|
||||
let param;
|
||||
let JSONBig = require('json-bigint')({ storeAsString: true });
|
||||
// 解决精度丢失问题
|
||||
|
|
|
@ -69,7 +69,7 @@ export default {
|
|||
open(objStr) {
|
||||
this.data = {};
|
||||
try {
|
||||
let stringedJSON = objStr.replace(/:\s*(?!.*\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}\+\d{2}:\d{2})\s([-+Ee0-9.]+)/g, ': "$1"');
|
||||
let stringedJSON = objStr.replace(/(?<=[:\[,])\s*(-?\d+(\.\d+)?)(?=\s*([,\]}]))/g, '"$1"');
|
||||
let param;
|
||||
let JSONBig = require('json-bigint')({"storeAsString": true});
|
||||
// 解决精度丢失问题
|
||||
|
|
Loading…
Reference in New Issue