feat_测试报告中增加断言原始脚本的内容 --story=1003877 --user=王孝刚 接口测试报告中,可以查看到断言脚本的原始脚本内容 https://www.tapd.cn/55049933/s/1065820
This commit is contained in:
parent
131d1979dd
commit
ca288fc05b
|
@ -19,7 +19,7 @@
|
|||
</div>
|
||||
|
||||
<el-divider/>
|
||||
<div class="request-bottom">
|
||||
<div class="request-middle">
|
||||
<api-report-reqest-header-item :title="$t('api_test.request.method')">
|
||||
<span class="method"> {{request.method}}</span>
|
||||
</api-report-reqest-header-item>
|
||||
|
@ -60,7 +60,12 @@
|
|||
{{$t('api_report.fail')}}
|
||||
</el-tag>
|
||||
</api-report-reqest-header-item>
|
||||
</div>
|
||||
|
||||
<div class="request-bottom">
|
||||
<div v-if="request.responseResult.assertions.length>0">
|
||||
<ms-assertion-results :assertions="request.responseResult.assertions"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-card>
|
||||
|
@ -76,12 +81,13 @@
|
|||
import MsMetricChart from "./components/MetricChart";
|
||||
import MsReportTitle from "../../../common/components/report/MsReportTitle";
|
||||
import MsReportExportTemplate from "../../../common/components/report/MsReportExportTemplate";
|
||||
import MsAssertionResults from "@/business/components/api/automation/report/components/AssertionResults"
|
||||
|
||||
export default {
|
||||
name: "MsApiReportExport",
|
||||
components: {
|
||||
MsReportExportTemplate,
|
||||
MsReportTitle, MsMetricChart, ApiReportReqestHeaderItem, MsRequestResultTail, MsScenarioResult
|
||||
MsReportTitle, MsMetricChart, ApiReportReqestHeaderItem, MsRequestResultTail, MsScenarioResult ,MsAssertionResults
|
||||
},
|
||||
props: {
|
||||
content: Object,
|
||||
|
@ -119,7 +125,7 @@
|
|||
font-weight: 500;
|
||||
}
|
||||
|
||||
.request-top, .request-bottom {
|
||||
.request-top, .request-bottom , .request-middle{
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<span>{{ !scope.row.name || scope.row.name === 'null' ? "" : scope.row.name }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="content" label="内容" width="200" show-overflow-tooltip/>
|
||||
<el-table-column prop="content" label="内容" width="300" show-overflow-tooltip/>
|
||||
<el-table-column prop="message" :label="$t('api_report.assertions_error_message')"/>
|
||||
<el-table-column prop="pass" :label="$t('api_report.assertions_is_success')" width="180">
|
||||
<template v-slot:default="{row}">
|
||||
|
|
|
@ -320,7 +320,7 @@ export default {
|
|||
handleTabClose() {
|
||||
let message = "";
|
||||
this.tabs.forEach(t => {
|
||||
if (t && this.$store.state.testCaseMap.has(t.testCaseInfo.id) && this.$store.state.testCaseMap.get(t.testCaseInfo.id) > 1) {
|
||||
if (t && this.$store.state.testCaseMap.has(t.testCaseInfo.id) && this.$store.state.testCaseMap.get(t.testCaseInfo.id) > 2) {
|
||||
message += t.testCaseInfo.name + ",";
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue