Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qa-platform-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
QA
qa-platform-ui
Commits
0e0ff489
Commit
0e0ff489
authored
Jul 08, 2021
by
晓彤
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
单个用例执行结果展示
parent
39baa2d2
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
52 additions
and
6 deletions
+52
-6
CaseList.vue
src/views/auto/CaseList.vue
+52
-6
No files found.
src/views/auto/CaseList.vue
View file @
0e0ff489
...
@@ -32,13 +32,51 @@
...
@@ -32,13 +32,51 @@
</el-card>
</el-card>
<!-- 接口返回数据 -->
<!-- 接口返回数据 -->
<el-card
v-if=
"isShow"
>
<el-card
v-if=
"isShow"
>
<div
slot=
"header"
>
<div
slot=
"header"
v-if=
"this.requestData.length>0"
style=
"margin-left:20px"
>
<el-row>
<el-row>
<el-col
:span=
"3"
>
<el-col
:span=
"2"
>
name:
</el-col>
<div>
响应结果 :
</div>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].name'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-col>
</el-row>
</el-row>
<json-viewer
:expand-depth=
3
:value=
"requestData"
></json-viewer>
<el-row>
<el-col
:span=
"2"
>
url:
</el-col>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].url'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"2"
>
headers:
</el-col>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].headers'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"2"
>
parameters:
</el-col>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].parameters'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"2"
>
response:
</el-col>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].response'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"2"
>
assertResult:
</el-col>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].assertResult'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"2"
>
elapsedTime:
</el-col>
<el-col
:span=
"22"
>
<json-viewer
:expand-depth=
3
:value=
'this.requestData[0].elapsedTime + "ms"'
style=
"margin-top:-25px"
></json-viewer>
</el-col>
</el-row>
</div>
</div>
</el-card>
</el-card>
</div>
</div>
...
@@ -71,7 +109,7 @@ export default {
...
@@ -71,7 +109,7 @@ export default {
testcaseId
:
''
testcaseId
:
''
},
},
isShow
:
false
,
isShow
:
false
,
requestData
:
''
requestData
:
[]
}
}
},
},
created
()
{
created
()
{
...
@@ -122,7 +160,15 @@ export default {
...
@@ -122,7 +160,15 @@ export default {
this
.
executeCaseParam
.
namespace
=
window
.
sessionStorage
.
getItem
(
'
env
'
)
this
.
executeCaseParam
.
namespace
=
window
.
sessionStorage
.
getItem
(
'
env
'
)
// 获取当前场景
// 获取当前场景
executeCase
(
this
.
executeCaseParam
).
then
((
resp
)
=>
{
executeCase
(
this
.
executeCaseParam
).
then
((
resp
)
=>
{
this
.
requestData
=
resp
.
data
.
data
var
resultData
=
resp
.
data
.
data
this
.
requestData
=
[]
// 将返回的对象数据转化成数组
this
.
requestData
.
push
(
resultData
)
if
(
resp
.
data
.
data
===
false
)
{
this
.
isShow
=
false
this
.
requestData
=
[]
this
.
$message
.
error
(
resp
.
data
.
msg
)
}
})
})
},
},
// 编辑用例
// 编辑用例
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment