fix(测试跟踪): 只有UI用例时测试计划屏蔽资源池选择框
--bug=1020120 --user=张大海 【UI测试】禁用本地执行资源池-测试计划-只关联了UI用例-执行计划提示“请选择资源池” https://www.tapd.cn/55049933/s/1303312
This commit is contained in:
parent
e821436d55
commit
217da690ce
|
@ -1639,10 +1639,6 @@ public class TestPlanService {
|
|||
return true;
|
||||
}
|
||||
|
||||
if (planTestPlanUiScenarioCaseService.haveUiCase(planId)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return planTestPlanLoadCaseService.haveExecCase(planId);
|
||||
}
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
<!-- 串行 -->
|
||||
<div
|
||||
class="mode-row"
|
||||
v-if="runConfig.mode === 'serial' && testType === 'API'"
|
||||
v-if="runConfig.mode === 'serial' && testType === 'API' && haveOtherExecCase"
|
||||
>
|
||||
<el-checkbox
|
||||
v-model="runConfig.runWithinResourcePool"
|
||||
|
@ -86,7 +86,7 @@
|
|||
<!-- 并行 -->
|
||||
<div
|
||||
class="mode-row"
|
||||
v-if="runConfig.mode === 'parallel' && testType === 'API'"
|
||||
v-if="runConfig.mode === 'parallel' && testType === 'API' && haveOtherExecCase"
|
||||
>
|
||||
<el-checkbox
|
||||
v-model="runConfig.runWithinResourcePool"
|
||||
|
@ -278,6 +278,10 @@ export default {
|
|||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
haveOtherExecCase: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
open(testType, runModeConfig) {
|
||||
|
|
|
@ -316,7 +316,7 @@
|
|||
:type="'plan'" :have-u-i-case="haveUICase"/>
|
||||
<ms-test-plan-schedule-batch-switch ref="scheduleBatchSwitch" @refresh="refresh"/>
|
||||
<ms-test-plan-run-mode-with-env @handleRunBatch="_handleRun" ref="runMode" :plan-case-ids="[]" :type="'plan'"
|
||||
:plan-id="currentPlanId" :show-save="true" :have-u-i-case="haveUICase"/>
|
||||
:plan-id="currentPlanId" :show-save="true" :have-u-i-case="haveUICase" :have-other-exec-case="haveOtherExecCase"/>
|
||||
<test-plan-report-review ref="testCaseReportView"/>
|
||||
<ms-task-center ref="taskCenter" :show-menu="false"/>
|
||||
<el-dialog
|
||||
|
@ -477,7 +477,10 @@ export default {
|
|||
},
|
||||
],
|
||||
batchExecuteType: "serial",
|
||||
haveUICase: false
|
||||
//是否有UI执行用例
|
||||
haveUICase: false,
|
||||
//是否有API/性能执行用例
|
||||
haveOtherExecCase: false,
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
|
@ -823,8 +826,9 @@ export default {
|
|||
.then(() => {
|
||||
testPlanHaveExecCase(row.id)
|
||||
.then(async res => {
|
||||
const haveExecCase = res.data;
|
||||
if (haveExecCase) {
|
||||
this.haveOtherExecCase = res.data;
|
||||
//因为ui没有资源池,这里必须分离两个变量
|
||||
if (this.haveOtherExecCase || this.haveUICase) {
|
||||
this.$refs.runMode.open('API', row.runModeConfig);
|
||||
} else {
|
||||
this.$router.push('/track/plan/view/' + row.id);
|
||||
|
|
Loading…
Reference in New Issue