From 2534eafcf0708d785c9f4a5e827553e640b7fbd5 Mon Sep 17 00:00:00 2001 From: Ambitiousliga <73278880+Ambitiousliga@users.noreply.github.com> Date: Tue, 30 Mar 2021 16:19:23 +0800 Subject: [PATCH 1/7] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA):?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=94=A8=E4=BE=8Bexcel=E5=AF=BC=E5=85=A5?= =?UTF-8?q?=E6=97=B6=E9=87=8D=E5=A4=8D=E6=A0=A1=E9=AA=8C=E4=B8=8D=E5=87=86?= =?UTF-8?q?=E7=A1=AE=E9=97=AE=E9=A2=98=E3=80=82=20(#1756)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: 黎龙鑫 Co-authored-by: jianxing <41557596+AgAngle@users.noreply.github.com> --- .../track/service/TestCaseService.java | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/backend/src/main/java/io/metersphere/track/service/TestCaseService.java b/backend/src/main/java/io/metersphere/track/service/TestCaseService.java index 881d60f382..d4f7a9cf12 100644 --- a/backend/src/main/java/io/metersphere/track/service/TestCaseService.java +++ b/backend/src/main/java/io/metersphere/track/service/TestCaseService.java @@ -182,25 +182,19 @@ public class TestCaseService { List caseList = testCaseMapper.selectByExampleWithBLOBs(example); - // 如果上边字段全部相同,去检查 steps 和 remark - boolean isExt = false; - String caseRemark = testCase.getRemark(); - if (StringUtils.isBlank(caseRemark)) { - caseRemark = ""; - } + // 如果上边字段全部相同,去检查 remark 和 steps if (!CollectionUtils.isEmpty(caseList)) { + String caseRemark = testCase.getRemark(); + String caseSteps = testCase.getSteps(); for (TestCaseWithBLOBs tc : caseList) { String steps = tc.getSteps(); String remark = tc.getRemark(); - if (StringUtils.equals(steps, testCase.getSteps()) && StringUtils.equals(remark, caseRemark)) { - //MSException.throwException(Translator.get("test_case_already_exists")); - isExt = true; + if (StringUtils.equals(steps, caseSteps) && StringUtils.equals(remark, caseRemark)) { + //MSException.throwException(Translator.get("test_case_already_exists")); + return tc; } } } - if (isExt) { - return caseList.get(0); - } } return null; } From ab987403212781bf47000431051daf672d777cb8 Mon Sep 17 00:00:00 2001 From: Ambitiousliga <73278880+Ambitiousliga@users.noreply.github.com> Date: Tue, 30 Mar 2021 16:17:08 +0800 Subject: [PATCH 2/7] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA):?= =?UTF-8?q?=E4=BD=BF=E5=8F=AA=E8=AF=BB=E7=94=A8=E6=88=B7=E4=B8=8D=E8=83=BD?= =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=B5=8B=E8=AF=95=E8=AE=A1=E5=88=92=E6=8A=A5?= =?UTF-8?q?=E5=91=8A=20(#1758)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: 黎龙鑫 --- .../components/track/report/components/TestPlanReportList.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/business/components/track/report/components/TestPlanReportList.vue b/frontend/src/business/components/track/report/components/TestPlanReportList.vue index b4b7049506..2058420062 100644 --- a/frontend/src/business/components/track/report/components/TestPlanReportList.vue +++ b/frontend/src/business/components/track/report/components/TestPlanReportList.vue @@ -20,7 +20,7 @@ @@ -49,7 +49,7 @@ + @exec="handleDelete(scope.row)" v-tester/> From 9abc90150d2a140510aedb0f4f78f01aff2ac39a Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Tue, 30 Mar 2021 16:38:30 +0800 Subject: [PATCH 3/7] =?UTF-8?q?fix(=E6=8E=A5=E5=8F=A3=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=8C=96):=20=E4=BF=AE=E5=A4=8D=E9=87=8D=E5=AE=9A=E5=90=91?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E5=86=85=E5=AE=B9=E9=87=8D=E5=A4=8D=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../io/metersphere/api/jmeter/APIBackendListenerClient.java | 4 ---- 1 file changed, 4 deletions(-) diff --git a/backend/src/main/java/io/metersphere/api/jmeter/APIBackendListenerClient.java b/backend/src/main/java/io/metersphere/api/jmeter/APIBackendListenerClient.java index fa14afa7fa..3ecf48632c 100644 --- a/backend/src/main/java/io/metersphere/api/jmeter/APIBackendListenerClient.java +++ b/backend/src/main/java/io/metersphere/api/jmeter/APIBackendListenerClient.java @@ -333,10 +333,6 @@ public class APIBackendListenerClient extends AbstractBackendListenerClient impl for (SampleResult subResult : result.getSubResults()) { requestResult.getSubRequestResults().add(getRequestResult(subResult)); } - for (SampleResult subResult : result.getSubResults()) { - requestResult.getSubRequestResults().add(getRequestResult(subResult)); - } - ResponseResult responseResult = requestResult.getResponseResult(); responseResult.setBody(result.getResponseDataAsString()); responseResult.setHeaders(result.getResponseHeaders()); From 32b26efc737b0a1708403aedd2ed190195c2904d Mon Sep 17 00:00:00 2001 From: chenjianxing Date: Tue, 30 Mar 2021 16:41:44 +0800 Subject: [PATCH 4/7] =?UTF-8?q?refactor:=20=E5=AF=BC=E5=85=A5=E7=94=A8?= =?UTF-8?q?=E4=BE=8B=E9=87=8D=E5=A4=8D=E6=8F=90=E7=A4=BA=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/src/main/resources/i18n/messages_zh_CN.properties | 2 +- backend/src/main/resources/i18n/messages_zh_TW.properties | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/src/main/resources/i18n/messages_zh_CN.properties b/backend/src/main/resources/i18n/messages_zh_CN.properties index ef493c103e..f158ce921c 100644 --- a/backend/src/main/resources/i18n/messages_zh_CN.properties +++ b/backend/src/main/resources/i18n/messages_zh_CN.properties @@ -144,7 +144,7 @@ password_format_is_incorrect=有效密码:8-30位,英文大小写字母+数 please_input_workspace_member=请填写该工作空间相关人员 test_case_report_template_repeat=同一工作空间下不能存在同名模版 plan_name_already_exists=测试计划名称已存在 -test_case_already_exists_excel=导入文件中存在重复用例 +test_case_already_exists_excel=文件中存在多条相同用例 test_case_module_already_exists=同层级下已存在该模块名称 api_test_name_already_exists=测试名称已经存在 functional_method_tip=功能测试不支持自动方式 diff --git a/backend/src/main/resources/i18n/messages_zh_TW.properties b/backend/src/main/resources/i18n/messages_zh_TW.properties index 85650bc3c6..321e8630fb 100644 --- a/backend/src/main/resources/i18n/messages_zh_TW.properties +++ b/backend/src/main/resources/i18n/messages_zh_TW.properties @@ -144,7 +144,7 @@ password_format_is_incorrect=有效密碼:8-30位,英文大小寫字母+數 please_input_workspace_member=請填寫該工作空間相關人員 test_case_report_template_repeat=同壹工作空間下不能存在同名模版 plan_name_already_exists=測試計劃名稱已存在 -test_case_already_exists_excel=導入文件中存在重復用例 +test_case_already_exists_excel=文件中存在多條相同用例 test_case_module_already_exists=同層級下已存在該模塊名稱 api_test_name_already_exists=測試名稱已經存在 functional_method_tip=功能測試不支持自動方式 From 0a7ce73e6ac0e5a8f5f5b00c18d1d3a56177a1d2 Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Tue, 30 Mar 2021 16:45:26 +0800 Subject: [PATCH 5/7] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E7=94=A8=E4=BE=8B):?= =?UTF-8?q?=20=E5=AF=BC=E5=85=A5xmind=20=E6=A8=A1=E7=89=88=20=E6=A8=A1?= =?UTF-8?q?=E5=9D=97=E5=90=8D=E7=A7=B0=E9=95=BF=E5=BA=A6=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/io/metersphere/xmind/XmindCaseParser.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java b/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java index 8a65db8a7b..d9d672385a 100644 --- a/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java +++ b/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java @@ -113,8 +113,8 @@ public class XmindCaseParser { for (int i = 0; i < nodes.length; i++) { if (i != 0 && StringUtils.equals(nodes[i].trim(), "")) { process.add(Translator.get("module_not_null"), path); - } else if (nodes[i].trim().length() > 30) { - process.add(Translator.get("module") + Translator.get("test_track.length_less_than") + "30", path + nodes[i].trim()); + } else if (nodes[i].trim().length() > 100) { + process.add(Translator.get("module") + Translator.get("test_track.length_less_than") + "100", path + nodes[i].trim()); } else { path += nodes[i].trim() + "/"; } @@ -150,8 +150,8 @@ public class XmindCaseParser { if (i != 0 && StringUtils.equals(nodes[i].trim(), "")) { process.add(Translator.get("test_case") + Translator.get("module_not_null"), nodePath + data.getName()); break; - } else if (nodes[i].trim().length() > 30) { - process.add(Translator.get("module") + Translator.get("test_track.length_less_than") + "30 ", nodes[i].trim()); + } else if (nodes[i].trim().length() > 100) { + process.add(Translator.get("module") + Translator.get("test_track.length_less_than") + "100 ", nodes[i].trim()); break; } } From af3d54b82f0483f276566a8f99c245000822c493 Mon Sep 17 00:00:00 2001 From: chenjianxing Date: Tue, 30 Mar 2021 16:59:45 +0800 Subject: [PATCH 6/7] =?UTF-8?q?refactor:=20jsonpath=E6=8E=A8=E8=8D=90?= =?UTF-8?q?=E5=85=B3=E9=97=AD=E6=8C=89=E9=92=AE=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../definition/components/assertion/ApiJsonpathSuggest.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/src/business/components/api/definition/components/assertion/ApiJsonpathSuggest.vue b/frontend/src/business/components/api/definition/components/assertion/ApiJsonpathSuggest.vue index cd25a48dac..4325ad5cc4 100644 --- a/frontend/src/business/components/api/definition/components/assertion/ApiJsonpathSuggest.vue +++ b/frontend/src/business/components/api/definition/components/assertion/ApiJsonpathSuggest.vue @@ -163,4 +163,9 @@ export default { margin-left: 6px; } + /deep/ .el-icon-close:hover { + font-size: 30px; + font-weight: bold; + } + From 3243e5fb684fd1d688131e0d8617083554f43c58 Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Tue, 30 Mar 2021 17:04:33 +0800 Subject: [PATCH 7/7] =?UTF-8?q?fix(=E5=9C=BA=E6=99=AF=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=8C=96):=20=E4=BF=AE=E5=A4=8D=E5=9C=BA=E6=99=AF=E5=90=8D?= =?UTF-8?q?=E7=A7=B0=E8=BF=87=E9=95=BF=E6=98=BE=E7=A4=BA=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../automation/scenario/EditApiScenario.vue | 21 +++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index 8978fd056a..09d3cdf8ce 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -100,7 +100,14 @@
- {{ currentScenario.name === undefined || '' ? $t('api_test.scenario.name') : currentScenario.name }} + + + + {{ currentScenario.name === undefined || '' ? $t('api_test.scenario.name') : currentScenario.name }} + + {{$t('api_test.automation.step_total')}}:{{scenarioDefinition.length}} @@ -447,7 +454,7 @@ }, }, methods: { - setModule(id,data) { + setModule(id, data) { this.currentScenario.apiScenarioModuleId = id; this.currentScenario.modulePath = data.path; }, @@ -1250,4 +1257,14 @@ font-size: 18px; } + .scenario-name { + display: inline-block; + margin: 0 5px; + overflow-x: hidden; + padding-bottom: 0; + text-overflow: ellipsis; + vertical-align: middle; + white-space: nowrap; + width: 200px; + }