From 3d3ac62b03087a0642fadc7792a1cd69a7baea58 Mon Sep 17 00:00:00 2001 From: guoyuqi Date: Thu, 23 Dec 2021 15:49:01 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=8E=A5=E5=8F=A3=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=8C=96):=20=E6=96=AD=E8=A8=80=E5=B0=86=E5=BF=BD=E7=95=A5?= =?UTF-8?q?=E7=A7=BB=E5=88=B0=E6=9C=80=E5=A4=96=E5=B1=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1004217 --user=郭雨琦 断言将忽略移到最外层 --- .../scenario/common/ApiBaseComponent.vue | 8 +++++++- .../components/assertion/ApiAssertionRegex.vue | 17 ++++++----------- .../components/assertion/ApiAssertions.vue | 3 +++ .../components/assertion/ApiAssertionRegex.vue | 17 ++++++----------- .../test/components/assertion/ApiAssertions.vue | 2 +- 5 files changed, 23 insertions(+), 24 deletions(-) diff --git a/frontend/src/business/components/api/automation/scenario/common/ApiBaseComponent.vue b/frontend/src/business/components/api/automation/scenario/common/ApiBaseComponent.vue index 8e6943bbcf..e39aa2d932 100644 --- a/frontend/src/business/components/api/automation/scenario/common/ApiBaseComponent.vue +++ b/frontend/src/business/components/api/automation/scenario/common/ApiBaseComponent.vue @@ -33,6 +33,9 @@
+ + {{ $t('api_test.request.assertions.ignore_status') }} + @@ -259,5 +262,8 @@ fieldset { cursor: pointer; border-color: #783887; } - +.assertion-checkbox { + text-align: center; + width: 120px; +} diff --git a/frontend/src/business/components/api/definition/components/assertion/ApiAssertionRegex.vue b/frontend/src/business/components/api/definition/components/assertion/ApiAssertionRegex.vue index 1feb9822d9..5953f1da93 100644 --- a/frontend/src/business/components/api/definition/components/assertion/ApiAssertionRegex.vue +++ b/frontend/src/business/components/api/definition/components/assertion/ApiAssertionRegex.vue @@ -13,11 +13,6 @@ - - - {{ $t('api_test.request.assertions.ignore_status') }} - - @@ -51,7 +46,11 @@ export default { isReadOnly: { type: Boolean, default: false - } + }, + assumeSuccess: { + type: Boolean, + default: false + }, }, data() { @@ -80,6 +79,7 @@ export default { getRegex() { let regex = new Regex(this.regex); regex.description = regex.subject + " has: " + regex.expression; + regex.assumeSuccess = this.assumeSuccess; return regex; }, setRegexDescription() { @@ -98,11 +98,6 @@ export default { width: 100%; } -.assertion-checkbox { - text-align: center; - width: 120px; -} - .assertion-btn { text-align: center; width: 60px; diff --git a/frontend/src/business/components/api/definition/components/assertion/ApiAssertions.vue b/frontend/src/business/components/api/definition/components/assertion/ApiAssertions.vue index 8a2fc2e7a2..608cae92b8 100644 --- a/frontend/src/business/components/api/definition/components/assertion/ApiAssertions.vue +++ b/frontend/src/business/components/api/definition/components/assertion/ApiAssertions.vue @@ -35,6 +35,7 @@ @@ -173,6 +174,7 @@ export default { this.reload(); }, copyRow() { + console.log("添加") this.$emit('copyRow', this.assertions, this.node); }, suggestJsonOpen() { @@ -217,6 +219,7 @@ export default { this.assertions.jsonPath = []; } } + } diff --git a/frontend/src/business/components/api/test/components/assertion/ApiAssertionRegex.vue b/frontend/src/business/components/api/test/components/assertion/ApiAssertionRegex.vue index b7da96c490..0db8904fc7 100644 --- a/frontend/src/business/components/api/test/components/assertion/ApiAssertionRegex.vue +++ b/frontend/src/business/components/api/test/components/assertion/ApiAssertionRegex.vue @@ -13,11 +13,6 @@ - - - {{ $t('api_test.request.assertions.ignore_status') }} - - @@ -52,7 +47,11 @@ export default { isReadOnly: { type: Boolean, default: false - } + }, + assumeSuccess: { + type: Boolean, + default: false + }, }, data() { @@ -81,6 +80,7 @@ export default { getRegex() { let regex = new Regex(this.regex); regex.description = regex.subject + " has: " + regex.expression; + regex.assumeSuccess = this.assumeSuccess; return regex; }, setRegexDescription() { @@ -99,11 +99,6 @@ export default { width: 100%; } -.assertion-checkbox { - text-align: center; - width: 120px; -} - .assertion-btn { text-align: center; width: 60px; diff --git a/frontend/src/business/components/api/test/components/assertion/ApiAssertions.vue b/frontend/src/business/components/api/test/components/assertion/ApiAssertions.vue index ab9cb388f0..c74fd2b82b 100644 --- a/frontend/src/business/components/api/test/components/assertion/ApiAssertions.vue +++ b/frontend/src/business/components/api/test/components/assertion/ApiAssertions.vue @@ -17,7 +17,7 @@ -