作者 bianxinhua

add README

正在显示 50 个修改的文件 包含 4792 行增加0 行删除

要显示太多修改。

为保证性能只显示 50 of 50+ 个文件。

#base_url=https://ability-test.fjmaimaimai.com
#base_public_url = http://public-interface-test.fjmaimaimai.com/
#base_public_url = https://public-interface.fjmaimaimai.com/mmm-partnermg/
#base_business_url = https://suplus-business-admin-gateway-test.fjmaimaimai.com/
#base_worth_url = https://suplus-worth-web-gateway-test.fjmaimaimai.com/
#base_manager_url= https://public-interface.fjmaimaimai.com/mmm-partnermg
base_manager_url=http://mmm-partnermg-test.fjmaimaimai.com/
base_url = http://mmm-partner-test.fjmaimaimai.com
... ...
不能预览此文件类型
不能预览此文件类型
name: 获取授权令牌:/v1/auth/accessToken
base_url: ${ENV(base_url)}
variables:
currtime1: ${make_time()}
uuid1: ${make_uuid()}
access_token1: ''
sign1: ${make_sign($currtime1, $uuid1, $access_token1)}
teardown_hooks:
- ${teardown_hook_get_accesstoken($response)}
- ${teardown_hook_get_refreshtoken($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token1
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '1'
X-MMM-Sign: $sign1
X-MMM-Timestamp: $currtime1
X-MMM-Uuid: $uuid1
X-MMM-Version: 0.4.0
json:
authCode: ${get_authcode()}
clientId: lks3Z8Ncn2j
clientSecret: gtfhyjukiol3Qncbvmdwe67khh
method: POST
url: /v1/auth/accessToken
\ No newline at end of file
... ...
name: 账号登录:/v1/auth/login
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ''
sign: ${make_sign($currtime, $uuid,$access_token)}
grantType: signInPassword
phone: ${convert_to_string(17770000005)}
password: 406f44fcef8d2e74db0f1b334c48369dcf6b38d0
teardown_hooks:
- ${teardown_hook_get_authcode($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.partner
X-MMM-AppProject: ability
X-MMM-DeviceType: '1'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.1.0
json:
phone: $phone
grantType: $grantType
password: $password
clientId: 'pdf233Znkjo'
method: POST
url: /v1/auth/login
... ...
name: 用户信息:
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
var_access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $var_access_token)}
teardown_hooks:
- ${teardown_hook_get_cuid($response)}
- ${teardown_hook_get_credentials($response)}
- ${teardown_hook_get_muid($response)}
- ${teardown_hook_get_cid($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $var_access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '1'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.4.0
json:
id: 1
method: POST
url: /v1/user/userInfo
... ...
name: APP版本升级
base_url: ${ENV(base_public_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: PartnerTest/20100 CFNetwork/1125.2 Darwin/19.4.0
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.maimaimai.partner
X-MMM-AppProject: partner
X-MMM-DeviceType: '1'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.1.0
json:
versionNo: '10003'
channel: $channel
method: POST
url: adminbase/version/getLatestVersionInfo
... ...
name: demo api
variables:
var1: value1
var2: value2
request:
url: /api/path/$var1
method: POST
headers:
Content-Type: "application/json"
json:
key: $var2
validate:
- eq: ["status_code", 200]
... ...
name: 管理员新增和修改:/v1/admin/update
base_url: ${ENV(base_manager_url)}
variables:
phone: 15005046165
password: d033e22ae348aeb5660fc2140aec35850c4da997
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
account: ${convert_to_string(13559112969)}
status: 1
id: 6
permissionType: [1,2,3]
method: POST
url: /v1/admin/update
... ...
name: 管理员详情:/v1/admin/detail
base_url: ${ENV(base_manager_url)}
variables:
# phone: 15005046165
# password: d033e22ae348aeb5660fc2140aec35850c4da997
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
id: 16
method: POST
url: /v1/admin/detail
... ...
name: 管理员禁用和启用:/v1/admin/forbidden
base_url: ${ENV(base_manager_url)}
variables:
phone: 15005046165
password: d033e22ae348aeb5660fc2140aec35850c4da997
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
id: 6
statue: 1
method: POST
url: /v1/admin/forbidden
... ...
name: 管理员列表:/v1/admin/list
base_url: ${ENV(base_manager_url)}
variables:
phone: 15005046165
password: d033e22ae348aeb5660fc2140aec35850c4da997
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
searchText:
pageNumber: 1
pageSize: 10
method: POST
url: /v1/admin/list
... ...
name: 管理员修改
base_url: ${ENV(base_manager_url)}
variables:
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer ${get_m_accesstoken()}
json:
account: ${convert_to_string(18800000009)}
status: 1
id: 59
permissionType: [6]
method: POST
url: /v1/admin/update
... ...
name: 管理员新增
base_url: ${ENV(base_manager_url)}
variables:
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer ${get_m_accesstoken()}
json:
account: ${convert_to_string($account)}
status: 1
# id: 6
permissionType: [2,3]
method: POST
url: /v1/admin/update
... ...
name: 账号登录
base_url: ${ENV(base_manager_url)}
variables:
username: ${convert_to_string(10000000001)}
password: 7c4a8d09ca3762af61e59520943dc26494f8941b
teardown_hooks:
- ${teardown_hook_get_m_accesstoken($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36
json:
password: $password
username: $username
method: POST
url: v1/auth/login
validate:
- eq:
- content.msg
- ok
... ...
name: 实际订单新增
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer ${get_m_accesstoken()}
json:
buyer: 我是买家${get_second()}
buyerPhone: ${convert_to_string(13459147023)}
address: '福建省福州市收获地址1'
partner: 2
partnerRatio: 1.1
salesmanRatio: 2.2
orderId: ${get_nowtime()}
orderName: ${get_nowtime()}
orderNum: 50
orderPrice: 100
orderDist: '福建一区'
orderStatue: 3
method: POST
url: /v1/order/actual/update
... ...
name: 意向订单新增
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer ${get_m_accesstoken()}
json:
buyer: 我是买家${get_second()}
buyerPhone: ${convert_to_string(13459147023)}
address: '福建省福州市收获地址1'
partner: 2
partnerRatio: 99.19
salesmanRatio: 0.99
orderId: ${get_nowtime()}
orderName: ${get_nowtime()}
orderNum: 50000000000
orderPrice: 1000000000
orderDist: '福建一区'
method: POST
url: v1/order/purpose/update
... ...
name: 合伙人添加
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer ${get_m_accesstoken()}
json:
partnerName: '卞信华'
partnerType: 3
area: '福建省福州市XXXXX区'
account: ${convert_to_string($account)}
state: 1
cooperationTime: '2020-07-30'
salesmanName: '小屁孩'
phone: ${convert_to_string($account)}
method: POST
url: v1/partners/add
... ...
name: /v1/partners/detail
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
id: 11
# account: ${convert_to_string(13559112969)}
# state: 1
# cooperationTime: '2020-06-28'
# salesmanName: '小张'
# phone: ${convert_to_string(15588888888)}
method: POST
url: /v1/partners/detail
... ...
name: 合伙人编辑
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer ${get_m_accesstoken()}
json:
partnerName: 'bxh002'
partnerType: 2
area: '福建省福州市一区'
account: ${convert_to_string(13459147027)}
state: 1
cooperationTime: '2020-06-30'
salesmanName: '小张'
phone: ${convert_to_string(13459147027)}
id: 22
method: POST
url: /v1/partners/edit
... ...
name: /v1/partners/list
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
partnerName:
partnerType:
area:
# account: ${convert_to_string(13559112969)}
# state: 1
# cooperationTime: '2020-06-28'
# salesmanName: '小张'
# phone: ${convert_to_string(15588888888)}
method: POST
url: /v1/partners/list
... ...
name: /v1/partners/set-status
base_url: ${ENV(base_manager_url)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1ODc0NTg0MjgsImlhdCI6MTU4NzQzNjgyNywiaXNzIjoibW1tX29wcG1nIiwibmJmIjoxNTg3NDM2ODI3LCJ1aWQiOjMyNDQ3NDc3Mjg1MzMyNDgsImNvbXBhbnlfaWQiOjM2MCwidXNlcl9jb21wYW55X2lkIjozMjQ0NzQ3NzI4NTMzMjQ4fQ.5t4HO5gbAXT_WXHGNf8ZsbXpPHrzsFhnuXWBtPZ4tWs
json:
status: 2
id: 9
method: POST
url: /v1/partners/set-status
... ...
name: /v1/auth/profile
base_url: ${ENV(base_manager_url)}
variables:
phone: 15005046165
password: d033e22ae348aeb5660fc2140aec35850c4da997
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTMzNTY2NjEsImlhdCI6MTU5MzMxMzQ2MSwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5MzMxMzQ2MSwidWlkIjo2fQ.UOh6EUisrD6gH2m3JrXwfLmRj3OpyaVK0SNwTETDwWk
json:
password: $password
username: ${convert_to_string(13559112969)}
method: POST
url: /v1/auth/profile
... ...
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjI5LCJleHAiOjE1OTM3OTI3ODcsImlzcyI6Imp3dCJ9.IxQHm091FrkOTCE3WTC3-1XycsdRsotllIujsKG8Zpg
\ No newline at end of file
... ...
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjI5LCJleHAiOjE1OTM3OTM2NTcsImlzcyI6Imp3dCJ9.RSktD87bv3wl2ctcQRaD9J9GbGPFDwWW1XKfRWrfAbQ
\ No newline at end of file
... ...
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5NjcxOTIsImlhdCI6MTU5MzkyMzk5MiwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5MzkyMzk5MiwidWlkIjoxfQ.doPUmNavAHSijOMKJGqNKVuXXqcGltIlOwFLXJcZ7Jk
\ No newline at end of file
... ...
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjI5LCJleHAiOjE1OTM3OTI4MTcsImlzcyI6Imp3dCJ9.uBQ0vYCvjdou4iQe9tQ9pS94XbjNTiJQTq48Czc5WMo
\ No newline at end of file
... ...
import random
import string
import time,datetime
from helpfunc.login_func import *
from helpfunc.db_func import *
from helpfunc.header_func import *
from random import randint
def sleep(n_secs):
time.sleep(n_secs)
def convert_to_string(value):
return str(value)
def get_nowtime():
return time.strftime("%Y%m%d%H%M%S",time.localtime(time.time()))
def get_second():
curr_time = datetime.datetime.now()
return curr_time.second
def create_channel(num):
channel = []
for i in range(num+1):
channel.append(i)
return channel
def create_phone_number(num):
phone_number = []
for i in range(num):
phone_number.append('189%08d'%i)
# print(phone_number)
return phone_number
... ...
# @Time :2019/11/26 11:22
# @Author :dengyuting
# @File :__init__.py.py
\ No newline at end of file
... ...
# @Time :2019/11/26 11:25
# @Author :dengyuting
# @File :db_func.py
import pymysql
db_config ={"host": "101.37.68.23",
"port": 3306,
"user": "dengyuting",
"password": "dyt_123456",
"db": "opportunity_test",
"charset": 'utf8'}
def get_id_from_database(tbl, company_id, column, column_value):
db = pymysql.connect(**db_config)
cursor = db.cursor()
company_id = str(company_id)
column_value = str(column_value)
sql= "select id from " + tbl + " where company_id=" + company_id + " and " + column + "=" + column_value + \
" and delete_at=0"
try:
cursor.execute(sql)
result = cursor.fetchone()
return result[0]
except Exception as err:
# 发生错误时回滚
print(err)
db.rollback()
db.close()
def get_chanceid_from_database(company_id):
db = pymysql.connect(**db_config)
cursor = db.cursor()
company_id = str(company_id)
sql= "select id from chance where company_id=" + company_id + " order by create_at desc"
try:
cursor.execute(sql)
result = cursor.fetchone()
return result[0]
except Exception as err:
# 发生错误时回滚
print(err)
db.rollback()
db.close()
def setup_hook_clean_db(companyid):
"""
初始化时清理数据库中对应公司的历史数据
:return:
"""
db = pymysql.connect(**db_config)
cursor = db.cursor()
companyid = str(companyid)
# get_adminid = 'select admin_id from company where id='+companyid
# get_user_company_id = 'select id from user_company where company_id='+companyid
try:
# cursor.execute(get_adminid)
# result = cursor.fetchone()
# admin_id = result[0]
# admin_id = str(admin_id)
# cursor.execute(get_user_company_id)
# result = cursor.fetchone()
# user_company_id = result[0]
# user_company_id = str(user_company_id)
# cursor.execute('delete from department where company_id=' + companyid + ' and is_top!=1')
# cursor.execute('delete from user_company where company_id=' + companyid + ' and user_id!='+admin_id)
# cursor.execute('delete from user_department where company_id=' + companyid + ' and user_company_id!='+ user_company_id)
# cursor.execute('delete from position where company_id=' + companyid)
# cursor.execute('delete from user_position where company_id=' + companyid)
# cursor.execute('delete from role where company_id=' + companyid + ' and is_default!=1')
# cursor.execute('delete from user_role where company_id=' + companyid)
# cursor.execute('delete from chance_type where company_id=' + companyid)
# cursor.execute('delete from audit_template where company_id=' + companyid)
# cursor.execute('delete from audit_form where company_id=' + companyid)
cursor.execute('delete a from chance_data a left JOIN chance b on a.chance_id=b.id where b.company_id=' + companyid)
db.commit()
cursor.execute('delete a from audit_flow_process a left JOIN chance b on a.chance_id=b.id where b.company_id=' + companyid)
db.commit()
cursor.execute('delete a from chance_department a left JOIN chance b on a.chance_id=b.id where b.company_id=' + companyid)
db.commit()
cursor.execute('delete from user_msg where receive_user_id in (select id from user_company where company_id=' + companyid + ') ' \
'or sender_user_id in (select id from user_company where company_id=' + companyid +')')
db.commit()
cursor.execute('delete from comment where user_id in (select id from user_company where company_id=' + companyid + ')')
db.commit()
cursor.execute('delete from chance_favorite where user_id in (select id from user_company where company_id=' + companyid + ')')
db.commit()
#这句要放在最后执行
cursor.execute('delete from chance where company_id=' + companyid)
db.commit()
print("delete OK")
except Exception as err:
# 发生错误时回滚
print("this is:", err)
db.rollback()
db.close()
\ No newline at end of file
... ...
# @Time :2019/11/26 11:24
# @Author :dengyuting
# @File :header_func.py
import hashlib
import time
import uuid
def make_time():
"""
生成当前时间戳
"""
return str(round(time.time() * 1000))
def make_uuid():
"""
基于MAC地址,时间戳,随机数来生成唯一的uuid,可以保证全球范围内的唯一性
"""
return str(uuid.uuid1())
def make_sign(currtime, uuid, accessstoken):
"""
生成签名
:param currtime:
:param uuid:
:param accessstoken:
:return:
"""
sign = 'v!(MmM' + currtime + uuid + accessstoken + 'MmM)i^'
sign = hashlib.sha256(sign.encode("utf-8"))
encrypts = sign.hexdigest()
return encrypts
\ No newline at end of file
... ...
# @Time :2019/11/26 11:23
# @Author :dengyuting
# @File :login_func.py
import json
def teardown_hook_get_accesstoken(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
access_token =jsondata['data']['accessToken']
try:
# 保存token到文件
with open('config/accessToken.csv','w+') as f:
f.write(access_token)
print('写入成功,access_token:{}'.format(access_token))
f.close()
except Exception as e:
print('写入失败', e)
return access_token
def teardown_hook_get_refreshtoken(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
refresh_token =jsondata['data']['refreshToken']
try:
# 保存token到文件
with open('config/refreshToken.csv','w+') as f:
f.write(refresh_token)
print('写入成功,refresh_token:{}'.format(refresh_token))
f.close()
except Exception as e:
print('写入失败', e)
return refresh_token
def teardown_hook_get_m_refreshtoken(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
m_refresh_token =jsondata['data']['access']['refresh_token']
try:
# 保存token到文件
with open('config/m_refresh_token.csv','w+') as f:
f.write(m_refresh_token)
print('写入成功,m_refresh_token:{}'.format(m_refresh_token))
f.close()
except Exception as e:
print('写入失败', e)
return m_refresh_token
def teardown_hook_get_authcode(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
authCode = jsondata['data']['authCode']
try:
# 保存token到文件
with open('config/authCode.csv','w+') as f:
f.write(authCode)
print('写入成功,authCode:{}'.format(authCode))
f.close()
except Exception as e:
print('写入失败', e)
return authCode
def teardown_hook_get_m_accesstoken(response):
print(response.status_code)
if response.status_code == 200:
jsondata = json.loads(response.text)
access_token = jsondata['data']['access']['accessToken']
try:
# 保存token到文件
with open('config/m_accessToken.csv','w+') as f:
f.write(access_token)
print('写入成功,access_token:{}'.format(access_token))
f.close()
except Exception as e:
print('写入失败', e)
return access_token
def get_accesstoken():
try:
with open('config/accessToken.csv','r') as f:
accseetoken_value = f.read()
print('读取accseetoken_value成功:{}'.format(accseetoken_value))
f.close()
except Exception as e:
print('读取失败', e)
accseetoken_value = str(accseetoken_value)
return accseetoken_value
def get_m_accesstoken():
try:
with open('config/m_accessToken.csv','r') as f:
accseetoken_value = f.read()
print('读取accseetoken_value成功:{}'.format(accseetoken_value))
f.close()
except Exception as e:
print('读取失败', e)
accseetoken_value = str(accseetoken_value)
authorization = 'bearer ' + accseetoken_value
return authorization
def get_m_refreshtoken():
try:
with open('config/m_refresh_token.csv','r') as f:
m_refreshtoken_value = f.read()
print('读取m_refreshtoken_value成功:{}'.format(m_refreshtoken_value))
f.close()
except Exception as e:
print('读取失败', e)
m_refreshtoken_value = str(m_refreshtoken_value)
authorization = 'bear ' + m_refreshtoken_value
return authorization
def get_refreshtoken():
try:
with open('config/refreshToken.csv','r') as f:
refreshtoken_value = f.read()
print('读取refreshtoken_value成功:{}'.format(refreshtoken_value))
f.close()
except Exception as e:
print('读取失败', e)
refreshtoken_value = str(refreshtoken_value)
return refreshtoken_value
def get_authcode():
try:
with open('config/authCode.csv','r') as f:
authcode_value = f.read()
print('读取authcode_value成功:{}'.format(authcode_value))
f.close()
except Exception as e:
print('读取失败', e)
authcode_value = str(authcode_value)
return authcode_value
\ No newline at end of file
... ...
{
"testcase":[
"E:/mmm_auto/partner/testcases/login_testcases.yml"
]
}
\ No newline at end of file
... ...
{
"testcase":[
"testcases/m_admin_login_testcases.yml"
]
}
\ No newline at end of file
... ...
此 diff 太大无法显示。
此 diff 太大无法显示。
<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">2020-07-04T14:53:21.546364</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.325 seconds</td>
</tr>
<tr>
<th>PLATFORM</th>
<td>HttpRunner 2.5.5 </td>
<td>CPython 3.8.1 </td>
<td colspan="2">Windows-7-6.1.7601-SP1</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>call demo_testcase with data 1</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">10000000001 登录系统</td>
<td style="text-align:center;width:6em;">214.01 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 登录系统</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;83&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;password&#34;: &#34;7c4a8d09ca3762af61e59520943dc26494f8941b&#34;,
&#34;username&#34;: &#34;10000000001&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:53:22 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Transfer-Encoding&#34;: &#34;chunked&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Vary&#34;: &#34;Accept-Encoding, Accept-Encoding&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;,
&#34;Content-Encoding&#34;: &#34;gzip&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {
&#34;access&#34;: {
&#34;accessToken&#34;: &#34;eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc2MDIsImlhdCI6MTU5Mzg3NDQwMiwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDQwMiwidWlkIjoxfQ.UxDe_mYaDvonOU1f98xBizsE5iIJBMmuYrFHBXlHY_8&#34;,
&#34;expiresIn&#34;: 43200
}
}
}</pre>
</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">
content.msg
</td>
<td>equals</td>
<td>ok</td>
<td>ok</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>310</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>214.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>204.213</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">10000000001 新增实际订单</td>
<td style="text-align:center;width:6em;">60.00 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 新增实际订单</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/actual/update
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;okhttp/3.12.3&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Authorization&#34;: &#34;Bearer bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc2MDIsImlhdCI6MTU5Mzg3NDQwMiwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDQwMiwidWlkIjoxfQ.UxDe_mYaDvonOU1f98xBizsE5iIJBMmuYrFHBXlHY_8&#34;,
&#34;Content-Length&#34;: &#34;368&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;buyer&#34;: &#34;我是买家21&#34;,
&#34;buyerPhone&#34;: &#34;13459147023&#34;,
&#34;address&#34;: &#34;福建省福州市收获地址1&#34;,
&#34;partner&#34;: 29,
&#34;partnerRatio&#34;: 99.99,
&#34;salesmanRatio&#34;: 22.11,
&#34;orderId&#34;: &#34;20200704225321&#34;,
&#34;orderName&#34;: &#34;20200704225321&#34;,
&#34;orderNum&#34;: 5000,
&#34;orderPrice&#34;: 100000000,
&#34;orderDist&#34;: &#34;福建一区&#34;,
&#34;orderStatue&#34;: 3
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/actual/update
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:53:22 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;55&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: -1,
&#34;msg&#34;: &#34;服务异常&#34;,
&#34;data&#34;: {}
}</pre>
</td>
</tr>
</table>
</div>
<h3>Validators:</h3>
<div style="overflow: auto">
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>55</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>60.0</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>56.931</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
</table>
</body>
\ No newline at end of file
... ...
<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">2020-07-04T14:55:29.449679</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.285 seconds</td>
</tr>
<tr>
<th>PLATFORM</th>
<td>HttpRunner 2.5.5 </td>
<td>CPython 3.8.1 </td>
<td colspan="2">Windows-7-6.1.7601-SP1</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>call demo_testcase with data 1</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">10000000001 登录系统</td>
<td style="text-align:center;width:6em;">193.01 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 登录系统</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;83&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;password&#34;: &#34;7c4a8d09ca3762af61e59520943dc26494f8941b&#34;,
&#34;username&#34;: &#34;10000000001&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:55:30 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Transfer-Encoding&#34;: &#34;chunked&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Vary&#34;: &#34;Accept-Encoding, Accept-Encoding&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;,
&#34;Content-Encoding&#34;: &#34;gzip&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {
&#34;access&#34;: {
&#34;accessToken&#34;: &#34;eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc3MzAsImlhdCI6MTU5Mzg3NDUzMCwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDUzMCwidWlkIjoxfQ.Z9saetn6R686E7a9ZkSvtmz5DlcDz246j2M5P-wN1Bk&#34;,
&#34;expiresIn&#34;: 43200
}
}
}</pre>
</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">
content.msg
</td>
<td>equals</td>
<td>ok</td>
<td>ok</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>310</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>193.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>184.756</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">10000000001 新增实际订单</td>
<td style="text-align:center;width:6em;">58.00 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 新增实际订单</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/actual/update
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;okhttp/3.12.3&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Authorization&#34;: &#34;Bearer bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc3MzAsImlhdCI6MTU5Mzg3NDUzMCwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDUzMCwidWlkIjoxfQ.Z9saetn6R686E7a9ZkSvtmz5DlcDz246j2M5P-wN1Bk&#34;,
&#34;Content-Length&#34;: &#34;368&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;buyer&#34;: &#34;我是买家29&#34;,
&#34;buyerPhone&#34;: &#34;13459147023&#34;,
&#34;address&#34;: &#34;福建省福州市收获地址1&#34;,
&#34;partner&#34;: 29,
&#34;partnerRatio&#34;: 99.99,
&#34;salesmanRatio&#34;: 22.11,
&#34;orderId&#34;: &#34;20200704225529&#34;,
&#34;orderName&#34;: &#34;20200704225529&#34;,
&#34;orderNum&#34;: 5000,
&#34;orderPrice&#34;: 100000000,
&#34;orderDist&#34;: &#34;福建一区&#34;,
&#34;orderStatue&#34;: 3
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/actual/update
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:55:30 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;55&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: -1,
&#34;msg&#34;: &#34;服务异常&#34;,
&#34;data&#34;: {}
}</pre>
</td>
</tr>
</table>
</div>
<h3>Validators:</h3>
<div style="overflow: auto">
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>55</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>58.0</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>53.305</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
</table>
</body>
\ No newline at end of file
... ...
<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">2020-07-04T14:57:33.571779</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.338 seconds</td>
</tr>
<tr>
<th>PLATFORM</th>
<td>HttpRunner 2.5.5 </td>
<td>CPython 3.8.1 </td>
<td colspan="2">Windows-7-6.1.7601-SP1</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>call demo_testcase with data 1</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">10000000001 登录系统</td>
<td style="text-align:center;width:6em;">213.01 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 登录系统</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;83&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;password&#34;: &#34;7c4a8d09ca3762af61e59520943dc26494f8941b&#34;,
&#34;username&#34;: &#34;10000000001&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:57:34 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Transfer-Encoding&#34;: &#34;chunked&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Vary&#34;: &#34;Accept-Encoding, Accept-Encoding&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;,
&#34;Content-Encoding&#34;: &#34;gzip&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {
&#34;access&#34;: {
&#34;accessToken&#34;: &#34;eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc4NTQsImlhdCI6MTU5Mzg3NDY1NCwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDY1NCwidWlkIjoxfQ.suICHO1_qAjGyM1dQz5LamZ_sAh9CxIYPjeiKnVFs-c&#34;,
&#34;expiresIn&#34;: 43200
}
}
}</pre>
</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">
content.msg
</td>
<td>equals</td>
<td>ok</td>
<td>ok</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>310</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>213.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>206.029</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">10000000001 新增实际订单</td>
<td style="text-align:center;width:6em;">59.00 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 新增实际订单</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/actual/update
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;okhttp/3.12.3&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Authorization&#34;: &#34;Bearer bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc4NTQsImlhdCI6MTU5Mzg3NDY1NCwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDY1NCwidWlkIjoxfQ.suICHO1_qAjGyM1dQz5LamZ_sAh9CxIYPjeiKnVFs-c&#34;,
&#34;Content-Length&#34;: &#34;367&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;buyer&#34;: &#34;我是买家33&#34;,
&#34;buyerPhone&#34;: &#34;13459147023&#34;,
&#34;address&#34;: &#34;福建省福州市收获地址1&#34;,
&#34;partner&#34;: 2,
&#34;partnerRatio&#34;: 99.99,
&#34;salesmanRatio&#34;: 22.11,
&#34;orderId&#34;: &#34;20200704225733&#34;,
&#34;orderName&#34;: &#34;20200704225733&#34;,
&#34;orderNum&#34;: 5000,
&#34;orderPrice&#34;: 100000000,
&#34;orderDist&#34;: &#34;福建一区&#34;,
&#34;orderStatue&#34;: 3
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/actual/update
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:57:34 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;44&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {}
}</pre>
</td>
</tr>
</table>
</div>
<h3>Validators:</h3>
<div style="overflow: auto">
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>44</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>59.0</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>56.028</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
</table>
</body>
\ No newline at end of file
... ...
<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">2020-07-04T14:59:08.560212</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.245 seconds</td>
</tr>
<tr>
<th>PLATFORM</th>
<td>HttpRunner 2.5.5 </td>
<td>CPython 3.8.1 </td>
<td colspan="2">Windows-7-6.1.7601-SP1</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>call demo_testcase with data 1</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">10000000001 登录系统</td>
<td style="text-align:center;width:6em;">158.01 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 登录系统</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;83&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;password&#34;: &#34;7c4a8d09ca3762af61e59520943dc26494f8941b&#34;,
&#34;username&#34;: &#34;10000000001&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:59:09 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Transfer-Encoding&#34;: &#34;chunked&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Vary&#34;: &#34;Accept-Encoding, Accept-Encoding&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;,
&#34;Content-Encoding&#34;: &#34;gzip&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {
&#34;access&#34;: {
&#34;accessToken&#34;: &#34;eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc5NDksImlhdCI6MTU5Mzg3NDc0OSwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDc0OSwidWlkIjoxfQ.2nZ_BgoEU8lQTbn-LGxW7SJgb0HIfa94-RQ463Qot9M&#34;,
&#34;expiresIn&#34;: 43200
}
}
}</pre>
</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">
content.msg
</td>
<td>equals</td>
<td>ok</td>
<td>ok</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>310</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>158.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>151.469</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">10000000001 新增意向订单</td>
<td style="text-align:center;width:6em;">58.00 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 新增意向订单</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/purpose/update
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;okhttp/3.12.3&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Authorization&#34;: &#34;Bearer bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTc5NDksImlhdCI6MTU5Mzg3NDc0OSwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDc0OSwidWlkIjoxfQ.2nZ_BgoEU8lQTbn-LGxW7SJgb0HIfa94-RQ463Qot9M&#34;,
&#34;Content-Length&#34;: &#34;347&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;buyer&#34;: &#34;我是买家8&#34;,
&#34;buyerPhone&#34;: &#34;13459147023&#34;,
&#34;address&#34;: &#34;福建省福州市收获地址1&#34;,
&#34;partner&#34;: 2,
&#34;partnerRatio&#34;: 99.19,
&#34;salesmanRatio&#34;: 0.99,
&#34;orderId&#34;: &#34;20200704225908&#34;,
&#34;orderName&#34;: &#34;20200704225908&#34;,
&#34;orderNum&#34;: 500,
&#34;orderPrice&#34;: 1000000000,
&#34;orderDist&#34;: &#34;福建一区&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/purpose/update
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 14:59:09 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;44&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {}
}</pre>
</td>
</tr>
</table>
</div>
<h3>Validators:</h3>
<div style="overflow: auto">
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>44</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>58.0</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>54.452</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
</table>
</body>
\ No newline at end of file
... ...
<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">2020-07-04T15:01:02.221713</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.194 seconds</td>
</tr>
<tr>
<th>PLATFORM</th>
<td>HttpRunner 2.5.5 </td>
<td>CPython 3.8.1 </td>
<td colspan="2">Windows-7-6.1.7601-SP1</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>call demo_testcase with data 1</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">10000000001 登录系统</td>
<td style="text-align:center;width:6em;">107.01 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 登录系统</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;83&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;password&#34;: &#34;7c4a8d09ca3762af61e59520943dc26494f8941b&#34;,
&#34;username&#34;: &#34;10000000001&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 15:01:02 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Transfer-Encoding&#34;: &#34;chunked&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Vary&#34;: &#34;Accept-Encoding, Accept-Encoding&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;,
&#34;Content-Encoding&#34;: &#34;gzip&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {
&#34;access&#34;: {
&#34;accessToken&#34;: &#34;eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTgwNjIsImlhdCI6MTU5Mzg3NDg2MiwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDg2MiwidWlkIjoxfQ.t-frysjdFqUWASwd7CBrw0HtiAxRbVX7CORhYnmDpMI&#34;,
&#34;expiresIn&#34;: 43200
}
}
}</pre>
</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">
content.msg
</td>
<td>equals</td>
<td>ok</td>
<td>ok</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>310</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>107.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>98.99</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">10000000001 新增意向订单</td>
<td style="text-align:center;width:6em;">41.00 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 新增意向订单</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/purpose/update
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;okhttp/3.12.3&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Authorization&#34;: &#34;Bearer bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTgwNjIsImlhdCI6MTU5Mzg3NDg2MiwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDg2MiwidWlkIjoxfQ.t-frysjdFqUWASwd7CBrw0HtiAxRbVX7CORhYnmDpMI&#34;,
&#34;Content-Length&#34;: &#34;347&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;buyer&#34;: &#34;我是买家2&#34;,
&#34;buyerPhone&#34;: &#34;13459147023&#34;,
&#34;address&#34;: &#34;福建省福州市收获地址1&#34;,
&#34;partner&#34;: 2,
&#34;partnerRatio&#34;: 99.19,
&#34;salesmanRatio&#34;: 0.99,
&#34;orderId&#34;: &#34;20200704230102&#34;,
&#34;orderName&#34;: &#34;20200704230102&#34;,
&#34;orderNum&#34;: 500,
&#34;orderPrice&#34;: 1000000000,
&#34;orderDist&#34;: &#34;福建一区&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/purpose/update
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 15:01:02 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;44&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {}
}</pre>
</td>
</tr>
</table>
</div>
<h3>Validators:</h3>
<div style="overflow: auto">
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>44</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>41.0</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>36.671</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
</table>
</body>
\ No newline at end of file
... ...
<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">2020-07-04T15:01:27.659168</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.204 seconds</td>
</tr>
<tr>
<th>PLATFORM</th>
<td>HttpRunner 2.5.5 </td>
<td>CPython 3.8.1 </td>
<td colspan="2">Windows-7-6.1.7601-SP1</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>call demo_testcase with data 1</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">10000000001 登录系统</td>
<td style="text-align:center;width:6em;">116.01 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 登录系统</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;83&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;password&#34;: &#34;7c4a8d09ca3762af61e59520943dc26494f8941b&#34;,
&#34;username&#34;: &#34;10000000001&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/auth/login
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 15:01:28 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Transfer-Encoding&#34;: &#34;chunked&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Vary&#34;: &#34;Accept-Encoding, Accept-Encoding&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;,
&#34;Content-Encoding&#34;: &#34;gzip&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {
&#34;access&#34;: {
&#34;accessToken&#34;: &#34;eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTgwODgsImlhdCI6MTU5Mzg3NDg4OCwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDg4OCwidWlkIjoxfQ.s8nznrxx2-Vumr4eAZbLXfiSjAT-C2nuw4b0ku7hcKg&#34;,
&#34;expiresIn&#34;: 43200
}
}
}</pre>
</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">
content.msg
</td>
<td>equals</td>
<td>ok</td>
<td>ok</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>310</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>116.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>109.639</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">10000000001 新增意向订单</td>
<td style="text-align:center;width:6em;">37.00 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">&times;</a>
<div class="content">
<h3>Name: 10000000001 新增意向订单</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/purpose/update
</td>
</tr>
<tr>
<th>method</th>
<td>
POST
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;User-Agent&#34;: &#34;okhttp/3.12.3&#34;,
&#34;Accept-Encoding&#34;: &#34;gzip, deflate&#34;,
&#34;Accept&#34;: &#34;*/*&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Content-Type&#34;: &#34;application/json;charset=utf-8&#34;,
&#34;Authorization&#34;: &#34;Bearer bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE1OTM5MTgwODgsImlhdCI6MTU5Mzg3NDg4OCwiaXNzIjoibW1tX3BhcnRuZXJtZyIsIm5iZiI6MTU5Mzg3NDg4OCwidWlkIjoxfQ.s8nznrxx2-Vumr4eAZbLXfiSjAT-C2nuw4b0ku7hcKg&#34;,
&#34;Content-Length&#34;: &#34;348&#34;
}</pre>
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;buyer&#34;: &#34;我是买家27&#34;,
&#34;buyerPhone&#34;: &#34;13459147023&#34;,
&#34;address&#34;: &#34;福建省福州市收获地址1&#34;,
&#34;partner&#34;: 2,
&#34;partnerRatio&#34;: 99.19,
&#34;salesmanRatio&#34;: 0.99,
&#34;orderId&#34;: &#34;20200704230127&#34;,
&#34;orderName&#34;: &#34;20200704230127&#34;,
&#34;orderNum&#34;: 500,
&#34;orderPrice&#34;: 1000000000,
&#34;orderDist&#34;: &#34;福建一区&#34;
}</pre>
</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>
https://public-interface.fjmaimaimai.com/mmm-partnermg/v1/order/purpose/update
</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>
utf-8
</td>
</tr>
<tr>
<th>headers</th>
<td>
<pre>{
&#34;Date&#34;: &#34;Sat, 04 Jul 2020 15:01:28 GMT&#34;,
&#34;Content-Type&#34;: &#34;application/json; charset=utf-8&#34;,
&#34;Content-Length&#34;: &#34;44&#34;,
&#34;Connection&#34;: &#34;keep-alive&#34;,
&#34;Access-Control-Allow-Credentials&#34;: &#34;true&#34;,
&#34;Access-Control-Allow-Headers&#34;: &#34;Origin,Authorization,Access-Control-Allow-Origin,Content-Type,x-requested-with&#34;,
&#34;Access-Control-Allow-Methods&#34;: &#34;*&#34;,
&#34;Access-Control-Allow-Origin&#34;: &#34;*&#34;,
&#34;Access-Control-Expose-Headers&#34;: &#34;Content-Length&#34;,
&#34;Strict-Transport-Security&#34;: &#34;max-age=15724800; includeSubDomains&#34;
}</pre>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json; charset=utf-8
</td>
</tr>
<tr>
<th>body</th>
<td>
<pre>{
&#34;code&#34;: 0,
&#34;msg&#34;: &#34;ok&#34;,
&#34;data&#34;: {}
}</pre>
</td>
</tr>
</table>
</div>
<h3>Validators:</h3>
<div style="overflow: auto">
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>44</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>37.0</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>33.911</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
</table>
</body>
\ No newline at end of file
... ...