mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-02 14:06:42 +08:00
774 lines
21 KiB
HTML
774 lines
21 KiB
HTML
<head>
|
|
<meta content="text/html; charset=utf-8" http-equiv="content-type" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title> - TestReport</title>
|
|
<style>
|
|
body {
|
|
background-color: #f2f2f2;
|
|
color: #333;
|
|
margin: 0 auto;
|
|
width: 960px;
|
|
}
|
|
#summary {
|
|
width: 960px;
|
|
margin-bottom: 20px;
|
|
}
|
|
#summary th {
|
|
background-color: skyblue;
|
|
padding: 5px 12px;
|
|
}
|
|
#summary td {
|
|
background-color: lightblue;
|
|
text-align: center;
|
|
padding: 4px 8px;
|
|
}
|
|
.details {
|
|
width: 960px;
|
|
margin-bottom: 20px;
|
|
}
|
|
.details th {
|
|
background-color: skyblue;
|
|
padding: 5px 12px;
|
|
}
|
|
.details tr .passed {
|
|
background-color: lightgreen;
|
|
}
|
|
.details tr .failed {
|
|
background-color: red;
|
|
}
|
|
.details tr .unchecked {
|
|
background-color: gray;
|
|
}
|
|
.details td {
|
|
background-color: lightblue;
|
|
padding: 5px 12px;
|
|
}
|
|
.details .detail {
|
|
background-color: lightgrey;
|
|
font-size: smaller;
|
|
padding: 5px 10px;
|
|
line-height: 20px;
|
|
text-align: left;
|
|
}
|
|
.details .success {
|
|
background-color: greenyellow;
|
|
}
|
|
.details .error {
|
|
background-color: red;
|
|
}
|
|
.details .failure {
|
|
background-color: salmon;
|
|
}
|
|
.details .skipped {
|
|
background-color: gray;
|
|
}
|
|
|
|
.button {
|
|
font-size: 1em;
|
|
padding: 6px;
|
|
width: 4em;
|
|
text-align: center;
|
|
background-color: #06d85f;
|
|
border-radius: 20px/50px;
|
|
cursor: pointer;
|
|
transition: all 0.3s ease-out;
|
|
}
|
|
a.button{
|
|
color: gray;
|
|
text-decoration: none;
|
|
display: inline-block;
|
|
}
|
|
.button:hover {
|
|
background: #2cffbd;
|
|
}
|
|
|
|
.overlay {
|
|
position: fixed;
|
|
top: 0;
|
|
bottom: 0;
|
|
left: 0;
|
|
right: 0;
|
|
background: rgba(0, 0, 0, 0.7);
|
|
transition: opacity 500ms;
|
|
visibility: hidden;
|
|
opacity: 0;
|
|
line-height: 25px;
|
|
}
|
|
.overlay:target {
|
|
visibility: visible;
|
|
opacity: 1;
|
|
}
|
|
|
|
.popup {
|
|
margin: 70px auto;
|
|
padding: 20px;
|
|
background: #fff;
|
|
border-radius: 10px;
|
|
width: 50%;
|
|
position: relative;
|
|
transition: all 3s ease-in-out;
|
|
}
|
|
|
|
.popup h2 {
|
|
margin-top: 0;
|
|
color: #333;
|
|
font-family: Tahoma, Arial, sans-serif;
|
|
}
|
|
.popup .close {
|
|
position: absolute;
|
|
top: 20px;
|
|
right: 30px;
|
|
transition: all 200ms;
|
|
font-size: 30px;
|
|
font-weight: bold;
|
|
text-decoration: none;
|
|
color: #333;
|
|
}
|
|
.popup .close:hover {
|
|
color: #06d85f;
|
|
}
|
|
.popup .content {
|
|
max-height: 80%;
|
|
overflow: auto;
|
|
text-align: left;
|
|
}
|
|
.popup .separator {
|
|
color:royalblue
|
|
}
|
|
|
|
@media screen and (max-width: 700px) {
|
|
.box {
|
|
width: 70%;
|
|
}
|
|
.popup {
|
|
width: 70%;
|
|
}
|
|
}
|
|
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<h1>Test Report: </h1>
|
|
|
|
<h2>Summary</h2>
|
|
<table id="summary">
|
|
<tr>
|
|
<th>START AT</th>
|
|
<td colspan="4">2019-01-27 11:52:50</td>
|
|
</tr>
|
|
<tr>
|
|
<th>DURATION</th>
|
|
<td colspan="4">0.039 seconds</td>
|
|
</tr>
|
|
<tr>
|
|
<th>PLATFORM</th>
|
|
<td>HttpRunner 2.0.2 </td>
|
|
<td>CPython 3.7.0 </td>
|
|
<td colspan="2">Darwin-18.2.0-x86_64-i386-64bit</td>
|
|
</tr>
|
|
<tr>
|
|
<th>STAT</th>
|
|
<th colspan="2">TESTCASES (success/fail)</th>
|
|
<th colspan="2">TESTSTEPS (success/fail/error/skip)</th>
|
|
</tr>
|
|
<tr>
|
|
<td>total (details) =></td>
|
|
<td colspan="2">1 (1/0)</td>
|
|
<td colspan="2">2 (2/0/0/0)</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<h2>Details</h2>
|
|
|
|
|
|
|
|
<h3>testcase description</h3>
|
|
<table id="suite_1" class="details">
|
|
<tr>
|
|
<td>TOTAL: 2</td>
|
|
<td>SUCCESS: 2</td>
|
|
<td>FAILED: 0</td>
|
|
<td>ERROR: 0</td>
|
|
<td>SKIPPED: 0</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Status</th>
|
|
<th colspan="2">Name</th>
|
|
<th>Response Time</th>
|
|
<th>Detail</th>
|
|
</tr>
|
|
|
|
|
|
|
|
|
|
<tr id="record_1_1">
|
|
<th class="success" style="width:5em;">success</th>
|
|
<td colspan="2">/api/get-token</td>
|
|
<td style="text-align:center;width:6em;">10.05 ms</td>
|
|
<td class="detail">
|
|
|
|
|
|
|
|
<a class="button" href="#popup_log_1_1_1">log-1</a>
|
|
<div id="popup_log_1_1_1" class="overlay">
|
|
<div class="popup">
|
|
<h2>Request and Response data</h2>
|
|
<a class="close" href="#record_1_1_1">×</a>
|
|
|
|
<div class="content">
|
|
<h3>Name: /api/get-token</h3>
|
|
|
|
|
|
|
|
|
|
|
|
<h3>Request:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
|
|
<tr>
|
|
<th>url</th>
|
|
<td>
|
|
|
|
http://127.0.0.1:5000/api/get-token
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>method</th>
|
|
<td>
|
|
|
|
POST
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>headers</th>
|
|
<td>
|
|
|
|
|
|
<div>
|
|
<strong>User-Agent</strong>: python-requests/2.18.4
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Accept-Encoding</strong>: gzip, deflate
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Accept</strong>: */*
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Connection</strong>: keep-alive
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Content-Type</strong>: application/json
|
|
</div>
|
|
|
|
<div>
|
|
<strong>app_version</strong>: 2.8.6
|
|
</div>
|
|
|
|
<div>
|
|
<strong>device_sn</strong>: rmZg1EL9KrDTxKB
|
|
</div>
|
|
|
|
<div>
|
|
<strong>os_platform</strong>: ios
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Content-Length</strong>: 52
|
|
</div>
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>body</th>
|
|
<td>
|
|
|
|
{"sign": "bd37c4f16cacb2bede7d9c853cc86b1fe36bfce6"}
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</div>
|
|
|
|
<h3>Response:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
|
|
<tr>
|
|
<th>ok</th>
|
|
<td>
|
|
|
|
True
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>url</th>
|
|
<td>
|
|
|
|
http://127.0.0.1:5000/api/get-token
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>status_code</th>
|
|
<td>
|
|
|
|
200
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>reason</th>
|
|
<td>
|
|
|
|
OK
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>cookies</th>
|
|
<td>
|
|
|
|
{}
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>encoding</th>
|
|
<td>
|
|
|
|
None
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>headers</th>
|
|
<td>
|
|
|
|
|
|
<div>
|
|
<strong>Content-Type</strong>: application/json
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Content-Length</strong>: 46
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Server</strong>: Werkzeug/0.14.1 Python/3.6.5+
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Date</strong>: Sun, 27 Jan 2019 03:52:50 GMT
|
|
</div>
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>content_type</th>
|
|
<td>
|
|
|
|
application/json
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>json</th>
|
|
<td>
|
|
|
|
{'success': True, 'token': 'PQTsjHOpmXulNB3l'}
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</div>
|
|
|
|
|
|
<h3>Validators:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
<tr>
|
|
<th>check</th>
|
|
<th>comparator</th>
|
|
<th>expect value</th>
|
|
<th>actual value</th>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
status_code
|
|
</td>
|
|
<td>eq</td>
|
|
<td>200</td>
|
|
<td>200</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
headers.Content-Type
|
|
</td>
|
|
<td>eq</td>
|
|
<td>application/json</td>
|
|
<td>application/json</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
content.success
|
|
</td>
|
|
<td>eq</td>
|
|
<td>True</td>
|
|
<td>True</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</div>
|
|
|
|
<h3>Statistics:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
<tr>
|
|
<th>content_size(bytes)</th>
|
|
<td>46</td>
|
|
</tr>
|
|
<tr>
|
|
<th>response_time(ms)</th>
|
|
<td>10.05</td>
|
|
</tr>
|
|
<tr>
|
|
<th>elapsed(ms)</th>
|
|
<td>3.483</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
|
|
|
|
<tr id="record_1_2">
|
|
<th class="success" style="width:5em;">success</th>
|
|
<td colspan="2">/api/users/1548561170497</td>
|
|
<td style="text-align:center;width:6em;">2.88 ms</td>
|
|
<td class="detail">
|
|
|
|
|
|
|
|
<a class="button" href="#popup_log_1_2_1">log-1</a>
|
|
<div id="popup_log_1_2_1" class="overlay">
|
|
<div class="popup">
|
|
<h2>Request and Response data</h2>
|
|
<a class="close" href="#record_1_2_1">×</a>
|
|
|
|
<div class="content">
|
|
<h3>Name: /api/users/1548561170497</h3>
|
|
|
|
|
|
|
|
|
|
|
|
<h3>Request:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
|
|
<tr>
|
|
<th>url</th>
|
|
<td>
|
|
|
|
http://127.0.0.1:5000/api/users/1548561170497
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>method</th>
|
|
<td>
|
|
|
|
POST
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>headers</th>
|
|
<td>
|
|
|
|
|
|
<div>
|
|
<strong>User-Agent</strong>: python-requests/2.18.4
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Accept-Encoding</strong>: gzip, deflate
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Accept</strong>: */*
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Connection</strong>: keep-alive
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Content-Type</strong>: application/json
|
|
</div>
|
|
|
|
<div>
|
|
<strong>device_sn</strong>: rmZg1EL9KrDTxKB
|
|
</div>
|
|
|
|
<div>
|
|
<strong>token</strong>: PQTsjHOpmXulNB3l
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Content-Length</strong>: 39
|
|
</div>
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>body</th>
|
|
<td>
|
|
|
|
{"name": "user1", "password": "123456"}
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</div>
|
|
|
|
<h3>Response:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
|
|
<tr>
|
|
<th>ok</th>
|
|
<td>
|
|
|
|
True
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>url</th>
|
|
<td>
|
|
|
|
http://127.0.0.1:5000/api/users/1548561170497
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>status_code</th>
|
|
<td>
|
|
|
|
201
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>reason</th>
|
|
<td>
|
|
|
|
CREATED
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>cookies</th>
|
|
<td>
|
|
|
|
{}
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>encoding</th>
|
|
<td>
|
|
|
|
None
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>headers</th>
|
|
<td>
|
|
|
|
|
|
<div>
|
|
<strong>Content-Type</strong>: application/json
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Content-Length</strong>: 54
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Server</strong>: Werkzeug/0.14.1 Python/3.6.5+
|
|
</div>
|
|
|
|
<div>
|
|
<strong>Date</strong>: Sun, 27 Jan 2019 03:52:50 GMT
|
|
</div>
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>content_type</th>
|
|
<td>
|
|
|
|
application/json
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th>json</th>
|
|
<td>
|
|
|
|
{'success': True, 'msg': 'user created successfully.'}
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</div>
|
|
|
|
|
|
<h3>Validators:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
<tr>
|
|
<th>check</th>
|
|
<th>comparator</th>
|
|
<th>expect value</th>
|
|
<th>actual value</th>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
status_code
|
|
</td>
|
|
<td>eq</td>
|
|
<td>201</td>
|
|
<td>201</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
headers.Content-Type
|
|
</td>
|
|
<td>eq</td>
|
|
<td>application/json</td>
|
|
<td>application/json</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
content.success
|
|
</td>
|
|
<td>eq</td>
|
|
<td>True</td>
|
|
<td>True</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="passed">
|
|
|
|
content.msg
|
|
</td>
|
|
<td>eq</td>
|
|
<td>user created successfully.</td>
|
|
<td>user created successfully.</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</div>
|
|
|
|
<h3>Statistics:</h3>
|
|
<div style="overflow: auto">
|
|
<table>
|
|
<tr>
|
|
<th>content_size(bytes)</th>
|
|
<td>54</td>
|
|
</tr>
|
|
<tr>
|
|
<th>response_time(ms)</th>
|
|
<td>2.88</td>
|
|
</tr>
|
|
<tr>
|
|
<th>elapsed(ms)</th>
|
|
<td>1.869</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
|
|
</table>
|
|
|
|
</body> |