refactor(接口测试): 报告步骤命名和场景步骤统一
--bug=1014239 --user=赵勇 【接口测试】github#15047场景用例执行成功后,等待控制器会变成英文 https://www.tapd.cn/55049933/s/1186534
This commit is contained in:
parent
bcdfb828c2
commit
eb4d89fb4d
|
@ -10,9 +10,9 @@
|
|||
</div>
|
||||
<el-tooltip effect="dark" :content="node.label" placement="top">
|
||||
<el-link v-if="node.redirect" class="report-label-head" @click="isLink">
|
||||
{{ node.label }}
|
||||
{{ getLable(node.label) }}
|
||||
</el-link>
|
||||
<span v-else>{{ node.label }}</span>
|
||||
<span v-else>{{ getLable(node.label) }}</span>
|
||||
</el-tooltip>
|
||||
</el-card>
|
||||
</div>
|
||||
|
@ -70,6 +70,18 @@ export default {
|
|||
}
|
||||
},
|
||||
methods: {
|
||||
getLable(label) {
|
||||
switch (label) {
|
||||
case "ConstantTimer":
|
||||
return "等待控制器";
|
||||
case "LoopController":
|
||||
return "循环控制器";
|
||||
case "Assertion":
|
||||
return "场景断言";
|
||||
default:
|
||||
return label;
|
||||
}
|
||||
},
|
||||
isLink() {
|
||||
let uri = "/#/api/automation?resourceId=" + this.node.resourceId;
|
||||
this.clickResource(uri)
|
||||
|
|
|
@ -86,9 +86,15 @@ export default {
|
|||
url = '/ui/automation/run/debug';
|
||||
}
|
||||
saveScenario(url, reqObj, this.runData.hashTree, this, (response) => {
|
||||
if(!response.success && response.data !== "SUCCESS"){
|
||||
// 兼容ui执行提示
|
||||
if (url.startsWith("/api") &&response.data!== "SUCCESS") {
|
||||
this.$error(response.data ? response.data : this.$t('commons.run_fail'));
|
||||
this.$emit('errorRefresh');
|
||||
} else {
|
||||
if (!response.success &&response.data!=="SUCCESS") {
|
||||
this.$error(response.data ? response.data : this.$t('commons.run_fail'));
|
||||
this.$emit('errorRefresh');
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue