feat(接口测试): 去除接口定义路径结尾空格

--bug=1033406 --user=宋昌昌 [接口测试]github#27838接口测试-接口定义,当接口路径最后有空格时,不会自动删除,会拼接到接口上 https://www.tapd.cn/55049933/s/1446804
This commit is contained in:
song-cc-rock 2023-12-21 13:57:21 +08:00 committed by 刘瑞斌
parent 7b0364f018
commit 8f617203b6
1 changed files with 11 additions and 8 deletions

View File

@ -334,6 +334,8 @@ export default {
this.sort(this.request.hashTree);
},
setParameter(data) {
// Path
data.path = data.path.trimEnd();
data.name = this.currentApi.name;
data.moduleId = this.currentApi.moduleId;
data.modulePath = this.currentApi.modulePath;
@ -431,6 +433,7 @@ export default {
setParameters(data) {
data.projectId = this.projectId;
this.request.name = this.currentApi.name;
this.request.path = this.currentApi.path.trimEnd();
data.protocol = this.currentProtocol;
data.request = this.request;
data.request.name = data.name;