Deployed e5fdf96 with MkDocs version: 1.0.4

This commit is contained in:
debugtalk 2019-11-01 23:17:45 +08:00
commit 9185128d87
136 changed files with 26949 additions and 0 deletions

0
.nojekyll Normal file
View File

693
404.html Normal file
View File

@ -0,0 +1,693 @@
<!doctype html>
<html lang="zh" class="no-js">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="HttpRunner V2.x User Documentation">
<meta name="author" content="debugtalk">
<meta name="lang:clipboard.copy" content="复制">
<meta name="lang:clipboard.copied" content="已复制">
<meta name="lang:search.language" content="jp">
<meta name="lang:search.pipeline.stopwords" content="True">
<meta name="lang:search.pipeline.trimmer" content="True">
<meta name="lang:search.result.none" content="没有找到符合条件的结果">
<meta name="lang:search.result.one" content="找到 1 个符合条件的结果">
<meta name="lang:search.result.other" content="# 个符合条件的结果">
<meta name="lang:search.tokenizer" content="[\uff0c\u3002]+">
<link rel="shortcut icon" href="/assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.0.4, mkdocs-material-4.4.3">
<title>HttpRunner V2.x 中文使用文档</title>
<link rel="stylesheet" href="/assets/stylesheets/application.30686662.css">
<link rel="stylesheet" href="/assets/stylesheets/application-palette.a8b3c06d.css">
<meta name="theme-color" content="#3f51b5">
<script src="/assets/javascripts/modernizr.74668098.js"></script>
<link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono&display=fallback">
<style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style>
<link rel="stylesheet" href="/assets/fonts/material-icons.css">
<script>
window.ga = window.ga || function() {
(ga.q = ga.q || []).push(arguments)
}
ga.l = +new Date
/* Setup integration and send page view */
ga("create", "UA-114587036-2", "auto")
ga("set", "anonymizeIp", true)
ga("send", "pageview")
/* Register handler to log search on blur */
document.addEventListener("DOMContentLoaded", () => {
if (document.forms.search) {
var query = document.forms.search.query
query.addEventListener("blur", function() {
if (this.value) {
var path = document.location.pathname;
ga("send", "pageview", path + "?q=" + this.value)
}
})
}
})
</script>
<script async src="https://www.google-analytics.com/analytics.js"></script>
</head>
<body dir="ltr" data-md-color-primary="indigo" data-md-color-accent="indigo">
<svg class="md-svg">
<defs>
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg>
</defs>
</svg>
<input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
<input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
<label class="md-overlay" data-md-component="overlay" for="__drawer"></label>
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<div class="md-flex">
<div class="md-flex__cell md-flex__cell--shrink">
<a href="/." title="HttpRunner V2.x 中文使用文档" class="md-header-nav__button md-logo">
<i class="md-icon"></i>
</a>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label>
</div>
<div class="md-flex__cell md-flex__cell--stretch">
<div class="md-flex__ellipsis md-header-nav__title" data-md-component="title">
<span class="md-header-nav__topic">
HttpRunner V2.x 中文使用文档
</span>
<span class="md-header-nav__topic">
</span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="__search"></label>
<div class="md-search" data-md-component="search" role="dialog">
<label class="md-search__overlay" for="__search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" placeholder="搜索" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active">
<label class="md-icon md-search__icon" for="__search"></label>
<button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1">
&#xE5CD;
</button>
</form>
<div class="md-search__output">
<div class="md-search__scrollwrap" data-md-scrollfix>
<div class="md-search-result" data-md-component="result">
<div class="md-search-result__meta">
键入以开始搜索
</div>
<ol class="md-search-result__list"></ol>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div class="md-header-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
</div>
</div>
</nav>
</header>
<div class="md-container">
<main class="md-main" role="main">
<div class="md-main__inner md-grid" data-md-component="container">
<div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--primary" data-md-level="0">
<label class="md-nav__title md-nav__title--site" for="__drawer">
<a href="/." title="HttpRunner V2.x 中文使用文档" class="md-nav__button md-logo">
<i class="md-icon"></i>
</a>
HttpRunner V2.x 中文使用文档
</label>
<div class="md-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/." title="介绍" class="md-nav__link">
介绍
</a>
</li>
<li class="md-nav__item">
<a href="/Installation/" title="安装说明" class="md-nav__link">
安装说明
</a>
</li>
<li class="md-nav__item">
<a href="/quickstart/" title="快速上手" class="md-nav__link">
快速上手
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-4" type="checkbox" id="nav-4">
<label class="md-nav__link" for="nav-4">
基础概念
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-4">
基础概念
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/concept/nominal/" title="名词解释" class="md-nav__link">
名词解释
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-5" type="checkbox" id="nav-5">
<label class="md-nav__link" for="nav-5">
测试准备
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-5">
测试准备
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/prepare/record/" title="录制生成用例" class="md-nav__link">
录制生成用例
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/project-structure/" title="项目文件组织" class="md-nav__link">
项目文件组织
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/testcase-structure/" title="测试用例组织" class="md-nav__link">
测试用例组织
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/request-hook/" title="hook机制" class="md-nav__link">
hook机制
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/dot-env/" title="环境变量" class="md-nav__link">
环境变量
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/testcase-layer/" title="测试用例分层" class="md-nav__link">
测试用例分层
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/parameters/" title="参数化数据驱动" class="md-nav__link">
参数化数据驱动
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/validate-pretty/" title="Validate & Prettify" class="md-nav__link">
Validate & Prettify
</a>
</li>
<li class="md-nav__item">
<a href="/prepare/security/" title="信息安全" class="md-nav__link">
信息安全
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-6" type="checkbox" id="nav-6">
<label class="md-nav__link" for="nav-6">
测试执行
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-6">
测试执行
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/run-tests/cli/" title="运行测试(CLI)" class="md-nav__link">
运行测试(CLI)
</a>
</li>
<li class="md-nav__item">
<a href="/run-tests/report/" title="测试报告" class="md-nav__link">
测试报告
</a>
</li>
<li class="md-nav__item">
<a href="/run-tests/load-test/" title="性能测试" class="md-nav__link">
性能测试
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-7" type="checkbox" id="nav-7">
<label class="md-nav__link" for="nav-7">
开发扩展
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-7">
开发扩展
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/development/architecture/" title="Pipline" class="md-nav__link">
Pipline
</a>
</li>
<li class="md-nav__item">
<a href="/development/dev-api/" title="基础库调用" class="md-nav__link">
基础库调用
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="/FAQ/" title="FAQ" class="md-nav__link">
FAQ
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-9" type="checkbox" id="nav-9">
<label class="md-nav__link" for="nav-9">
实践案例
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-9">
实践案例
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/examples/testerhome-login/" title="TesterHome 登录" class="md-nav__link">
TesterHome 登录
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="/related-docs/" title="相关资料" class="md-nav__link">
相关资料
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-content">
<article class="md-content__inner md-typeset">
<h1>404 - Not found</h1>
</article>
</div>
</div>
</main>
<footer class="md-footer">
<div class="md-footer-meta md-typeset">
<div class="md-footer-meta__inner md-grid">
<div class="md-footer-copyright">
<div class="md-footer-copyright__highlight">
Copyright &copy; 2017 - 2019 debugtalk
</div>
powered by
<a href="https://www.mkdocs.org">MkDocs</a>
and
<a href="https://squidfunk.github.io/mkdocs-material/">
Material for MkDocs</a>
</div>
<div class="md-footer-social">
<link rel="stylesheet" href="/assets/fonts/font-awesome.css">
<a href="https://debugtalk.com" class="md-footer-social__link fa fa-globe"></a>
<a href="https://github.com/httprunner" class="md-footer-social__link fa fa-github"></a>
</div>
</div>
</div>
</footer>
</div>
<script src="/assets/javascripts/application.ac79c3b0.js"></script>
<script src="/assets/javascripts/lunr/lunr.stemmer.support.js"></script>
<script>app.initialize({version:"1.0.4",url:{base:"/"}})</script>
<script src="/js/slardar.js"></script>
</body>
</html>

1
CNAME Normal file
View File

@ -0,0 +1 @@
docs.httprunner.org

761
FAQ/index.html Normal file
View File

@ -0,0 +1,761 @@
<!doctype html>
<html lang="zh" class="no-js">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="HttpRunner V2.x User Documentation">
<meta name="author" content="debugtalk">
<meta name="lang:clipboard.copy" content="复制">
<meta name="lang:clipboard.copied" content="已复制">
<meta name="lang:search.language" content="jp">
<meta name="lang:search.pipeline.stopwords" content="True">
<meta name="lang:search.pipeline.trimmer" content="True">
<meta name="lang:search.result.none" content="没有找到符合条件的结果">
<meta name="lang:search.result.one" content="找到 1 个符合条件的结果">
<meta name="lang:search.result.other" content="# 个符合条件的结果">
<meta name="lang:search.tokenizer" content="[\uff0c\u3002]+">
<link rel="shortcut icon" href="../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.0.4, mkdocs-material-4.4.3">
<title>FAQ - HttpRunner V2.x 中文使用文档</title>
<link rel="stylesheet" href="../assets/stylesheets/application.30686662.css">
<link rel="stylesheet" href="../assets/stylesheets/application-palette.a8b3c06d.css">
<meta name="theme-color" content="#3f51b5">
<script src="../assets/javascripts/modernizr.74668098.js"></script>
<link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono&display=fallback">
<style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style>
<link rel="stylesheet" href="../assets/fonts/material-icons.css">
<script>
window.ga = window.ga || function() {
(ga.q = ga.q || []).push(arguments)
}
ga.l = +new Date
/* Setup integration and send page view */
ga("create", "UA-114587036-2", "auto")
ga("set", "anonymizeIp", true)
ga("send", "pageview")
/* Register handler to log search on blur */
document.addEventListener("DOMContentLoaded", () => {
if (document.forms.search) {
var query = document.forms.search.query
query.addEventListener("blur", function() {
if (this.value) {
var path = document.location.pathname;
ga("send", "pageview", path + "?q=" + this.value)
}
})
}
})
</script>
<script async src="https://www.google-analytics.com/analytics.js"></script>
</head>
<body dir="ltr" data-md-color-primary="indigo" data-md-color-accent="indigo">
<svg class="md-svg">
<defs>
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg>
</defs>
</svg>
<input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
<input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
<label class="md-overlay" data-md-component="overlay" for="__drawer"></label>
<a href="#_1" tabindex="1" class="md-skip">
跳转至
</a>
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<div class="md-flex">
<div class="md-flex__cell md-flex__cell--shrink">
<a href=".." title="HttpRunner V2.x 中文使用文档" class="md-header-nav__button md-logo">
<i class="md-icon"></i>
</a>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label>
</div>
<div class="md-flex__cell md-flex__cell--stretch">
<div class="md-flex__ellipsis md-header-nav__title" data-md-component="title">
<span class="md-header-nav__topic">
HttpRunner V2.x 中文使用文档
</span>
<span class="md-header-nav__topic">
FAQ
</span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="__search"></label>
<div class="md-search" data-md-component="search" role="dialog">
<label class="md-search__overlay" for="__search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" placeholder="搜索" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active">
<label class="md-icon md-search__icon" for="__search"></label>
<button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1">
&#xE5CD;
</button>
</form>
<div class="md-search__output">
<div class="md-search__scrollwrap" data-md-scrollfix>
<div class="md-search-result" data-md-component="result">
<div class="md-search-result__meta">
键入以开始搜索
</div>
<ol class="md-search-result__list"></ol>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div class="md-header-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
</div>
</div>
</nav>
</header>
<div class="md-container">
<main class="md-main" role="main">
<div class="md-main__inner md-grid" data-md-component="container">
<div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--primary" data-md-level="0">
<label class="md-nav__title md-nav__title--site" for="__drawer">
<a href=".." title="HttpRunner V2.x 中文使用文档" class="md-nav__button md-logo">
<i class="md-icon"></i>
</a>
HttpRunner V2.x 中文使用文档
</label>
<div class="md-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href=".." title="介绍" class="md-nav__link">
介绍
</a>
</li>
<li class="md-nav__item">
<a href="../Installation/" title="安装说明" class="md-nav__link">
安装说明
</a>
</li>
<li class="md-nav__item">
<a href="../quickstart/" title="快速上手" class="md-nav__link">
快速上手
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-4" type="checkbox" id="nav-4">
<label class="md-nav__link" for="nav-4">
基础概念
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-4">
基础概念
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../concept/nominal/" title="名词解释" class="md-nav__link">
名词解释
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-5" type="checkbox" id="nav-5">
<label class="md-nav__link" for="nav-5">
测试准备
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-5">
测试准备
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../prepare/record/" title="录制生成用例" class="md-nav__link">
录制生成用例
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/project-structure/" title="项目文件组织" class="md-nav__link">
项目文件组织
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/testcase-structure/" title="测试用例组织" class="md-nav__link">
测试用例组织
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/request-hook/" title="hook机制" class="md-nav__link">
hook机制
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/dot-env/" title="环境变量" class="md-nav__link">
环境变量
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/testcase-layer/" title="测试用例分层" class="md-nav__link">
测试用例分层
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/parameters/" title="参数化数据驱动" class="md-nav__link">
参数化数据驱动
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/validate-pretty/" title="Validate & Prettify" class="md-nav__link">
Validate & Prettify
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/security/" title="信息安全" class="md-nav__link">
信息安全
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-6" type="checkbox" id="nav-6">
<label class="md-nav__link" for="nav-6">
测试执行
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-6">
测试执行
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../run-tests/cli/" title="运行测试(CLI)" class="md-nav__link">
运行测试(CLI)
</a>
</li>
<li class="md-nav__item">
<a href="../run-tests/report/" title="测试报告" class="md-nav__link">
测试报告
</a>
</li>
<li class="md-nav__item">
<a href="../run-tests/load-test/" title="性能测试" class="md-nav__link">
性能测试
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-7" type="checkbox" id="nav-7">
<label class="md-nav__link" for="nav-7">
开发扩展
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-7">
开发扩展
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../development/architecture/" title="Pipline" class="md-nav__link">
Pipline
</a>
</li>
<li class="md-nav__item">
<a href="../development/dev-api/" title="基础库调用" class="md-nav__link">
基础库调用
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--active">
<input class="md-toggle md-nav__toggle" data-md-toggle="toc" type="checkbox" id="__toc">
<a href="./" title="FAQ" class="md-nav__link md-nav__link--active">
FAQ
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-9" type="checkbox" id="nav-9">
<label class="md-nav__link" for="nav-9">
实践案例
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-9">
实践案例
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../examples/testerhome-login/" title="TesterHome 登录" class="md-nav__link">
TesterHome 登录
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../related-docs/" title="相关资料" class="md-nav__link">
相关资料
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-sidebar md-sidebar--secondary" data-md-component="toc">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--secondary">
</nav>
</div>
</div>
</div>
<div class="md-content">
<article class="md-content__inner md-typeset">
<h1 id="_1">常见问题<a class="headerlink" href="#_1" title="Permanent link">&para;</a></h1>
</article>
</div>
</div>
</main>
<footer class="md-footer">
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid">
<a href="../development/dev-api/" title="基础库调用" class="md-flex md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-back md-footer-nav__button"></i>
</div>
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
上一页
</span>
基础库调用
</span>
</div>
</a>
<a href="../examples/testerhome-login/" title="TesterHome 登录" class="md-flex md-footer-nav__link md-footer-nav__link--next" rel="next">
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
下一页
</span>
TesterHome 登录
</span>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-forward md-footer-nav__button"></i>
</div>
</a>
</nav>
</div>
<div class="md-footer-meta md-typeset">
<div class="md-footer-meta__inner md-grid">
<div class="md-footer-copyright">
<div class="md-footer-copyright__highlight">
Copyright &copy; 2017 - 2019 debugtalk
</div>
powered by
<a href="https://www.mkdocs.org">MkDocs</a>
and
<a href="https://squidfunk.github.io/mkdocs-material/">
Material for MkDocs</a>
</div>
<div class="md-footer-social">
<link rel="stylesheet" href="../assets/fonts/font-awesome.css">
<a href="https://debugtalk.com" class="md-footer-social__link fa fa-globe"></a>
<a href="https://github.com/httprunner" class="md-footer-social__link fa fa-github"></a>
</div>
</div>
</div>
</footer>
</div>
<script src="../assets/javascripts/application.ac79c3b0.js"></script>
<script src="../assets/javascripts/lunr/lunr.stemmer.support.js"></script>
<script>app.initialize({version:"1.0.4",url:{base:".."}})</script>
<script src="../js/slardar.js"></script>
</body>
</html>

971
Installation/index.html Normal file
View File

@ -0,0 +1,971 @@
<!doctype html>
<html lang="zh" class="no-js">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="HttpRunner V2.x User Documentation">
<meta name="author" content="debugtalk">
<meta name="lang:clipboard.copy" content="复制">
<meta name="lang:clipboard.copied" content="已复制">
<meta name="lang:search.language" content="jp">
<meta name="lang:search.pipeline.stopwords" content="True">
<meta name="lang:search.pipeline.trimmer" content="True">
<meta name="lang:search.result.none" content="没有找到符合条件的结果">
<meta name="lang:search.result.one" content="找到 1 个符合条件的结果">
<meta name="lang:search.result.other" content="# 个符合条件的结果">
<meta name="lang:search.tokenizer" content="[\uff0c\u3002]+">
<link rel="shortcut icon" href="../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.0.4, mkdocs-material-4.4.3">
<title>安装说明 - HttpRunner V2.x 中文使用文档</title>
<link rel="stylesheet" href="../assets/stylesheets/application.30686662.css">
<link rel="stylesheet" href="../assets/stylesheets/application-palette.a8b3c06d.css">
<meta name="theme-color" content="#3f51b5">
<script src="../assets/javascripts/modernizr.74668098.js"></script>
<link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono&display=fallback">
<style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style>
<link rel="stylesheet" href="../assets/fonts/material-icons.css">
<script>
window.ga = window.ga || function() {
(ga.q = ga.q || []).push(arguments)
}
ga.l = +new Date
/* Setup integration and send page view */
ga("create", "UA-114587036-2", "auto")
ga("set", "anonymizeIp", true)
ga("send", "pageview")
/* Register handler to log search on blur */
document.addEventListener("DOMContentLoaded", () => {
if (document.forms.search) {
var query = document.forms.search.query
query.addEventListener("blur", function() {
if (this.value) {
var path = document.location.pathname;
ga("send", "pageview", path + "?q=" + this.value)
}
})
}
})
</script>
<script async src="https://www.google-analytics.com/analytics.js"></script>
</head>
<body dir="ltr" data-md-color-primary="indigo" data-md-color-accent="indigo">
<svg class="md-svg">
<defs>
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg>
</defs>
</svg>
<input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
<input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
<label class="md-overlay" data-md-component="overlay" for="__drawer"></label>
<a href="#_1" tabindex="1" class="md-skip">
跳转至
</a>
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<div class="md-flex">
<div class="md-flex__cell md-flex__cell--shrink">
<a href=".." title="HttpRunner V2.x 中文使用文档" class="md-header-nav__button md-logo">
<i class="md-icon"></i>
</a>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label>
</div>
<div class="md-flex__cell md-flex__cell--stretch">
<div class="md-flex__ellipsis md-header-nav__title" data-md-component="title">
<span class="md-header-nav__topic">
HttpRunner V2.x 中文使用文档
</span>
<span class="md-header-nav__topic">
安装说明
</span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="__search"></label>
<div class="md-search" data-md-component="search" role="dialog">
<label class="md-search__overlay" for="__search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" placeholder="搜索" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active">
<label class="md-icon md-search__icon" for="__search"></label>
<button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1">
&#xE5CD;
</button>
</form>
<div class="md-search__output">
<div class="md-search__scrollwrap" data-md-scrollfix>
<div class="md-search-result" data-md-component="result">
<div class="md-search-result__meta">
键入以开始搜索
</div>
<ol class="md-search-result__list"></ol>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div class="md-header-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
</div>
</div>
</nav>
</header>
<div class="md-container">
<main class="md-main" role="main">
<div class="md-main__inner md-grid" data-md-component="container">
<div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--primary" data-md-level="0">
<label class="md-nav__title md-nav__title--site" for="__drawer">
<a href=".." title="HttpRunner V2.x 中文使用文档" class="md-nav__button md-logo">
<i class="md-icon"></i>
</a>
HttpRunner V2.x 中文使用文档
</label>
<div class="md-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href=".." title="介绍" class="md-nav__link">
介绍
</a>
</li>
<li class="md-nav__item md-nav__item--active">
<input class="md-toggle md-nav__toggle" data-md-toggle="toc" type="checkbox" id="__toc">
<label class="md-nav__link md-nav__link--active" for="__toc">
安装说明
</label>
<a href="./" title="安装说明" class="md-nav__link md-nav__link--active">
安装说明
</a>
<nav class="md-nav md-nav--secondary">
<label class="md-nav__title" for="__toc">目录</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="#_1" class="md-nav__link">
运行环境
</a>
</li>
<li class="md-nav__item">
<a href="#_2" class="md-nav__link">
安装方式
</a>
</li>
<li class="md-nav__item">
<a href="#_3" class="md-nav__link">
版本升级
</a>
</li>
<li class="md-nav__item">
<a href="#_4" class="md-nav__link">
安装校验
</a>
</li>
<li class="md-nav__item">
<a href="#_5" class="md-nav__link">
开发者模式
</a>
</li>
<li class="md-nav__item">
<a href="#docker" class="md-nav__link">
Docker
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../quickstart/" title="快速上手" class="md-nav__link">
快速上手
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-4" type="checkbox" id="nav-4">
<label class="md-nav__link" for="nav-4">
基础概念
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-4">
基础概念
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../concept/nominal/" title="名词解释" class="md-nav__link">
名词解释
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-5" type="checkbox" id="nav-5">
<label class="md-nav__link" for="nav-5">
测试准备
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-5">
测试准备
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../prepare/record/" title="录制生成用例" class="md-nav__link">
录制生成用例
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/project-structure/" title="项目文件组织" class="md-nav__link">
项目文件组织
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/testcase-structure/" title="测试用例组织" class="md-nav__link">
测试用例组织
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/request-hook/" title="hook机制" class="md-nav__link">
hook机制
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/dot-env/" title="环境变量" class="md-nav__link">
环境变量
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/testcase-layer/" title="测试用例分层" class="md-nav__link">
测试用例分层
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/parameters/" title="参数化数据驱动" class="md-nav__link">
参数化数据驱动
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/validate-pretty/" title="Validate & Prettify" class="md-nav__link">
Validate & Prettify
</a>
</li>
<li class="md-nav__item">
<a href="../prepare/security/" title="信息安全" class="md-nav__link">
信息安全
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-6" type="checkbox" id="nav-6">
<label class="md-nav__link" for="nav-6">
测试执行
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-6">
测试执行
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../run-tests/cli/" title="运行测试(CLI)" class="md-nav__link">
运行测试(CLI)
</a>
</li>
<li class="md-nav__item">
<a href="../run-tests/report/" title="测试报告" class="md-nav__link">
测试报告
</a>
</li>
<li class="md-nav__item">
<a href="../run-tests/load-test/" title="性能测试" class="md-nav__link">
性能测试
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-7" type="checkbox" id="nav-7">
<label class="md-nav__link" for="nav-7">
开发扩展
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-7">
开发扩展
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../development/architecture/" title="Pipline" class="md-nav__link">
Pipline
</a>
</li>
<li class="md-nav__item">
<a href="../development/dev-api/" title="基础库调用" class="md-nav__link">
基础库调用
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../FAQ/" title="FAQ" class="md-nav__link">
FAQ
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-9" type="checkbox" id="nav-9">
<label class="md-nav__link" for="nav-9">
实践案例
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-9">
实践案例
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../examples/testerhome-login/" title="TesterHome 登录" class="md-nav__link">
TesterHome 登录
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../related-docs/" title="相关资料" class="md-nav__link">
相关资料
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-sidebar md-sidebar--secondary" data-md-component="toc">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--secondary">
<label class="md-nav__title" for="__toc">目录</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="#_1" class="md-nav__link">
运行环境
</a>
</li>
<li class="md-nav__item">
<a href="#_2" class="md-nav__link">
安装方式
</a>
</li>
<li class="md-nav__item">
<a href="#_3" class="md-nav__link">
版本升级
</a>
</li>
<li class="md-nav__item">
<a href="#_4" class="md-nav__link">
安装校验
</a>
</li>
<li class="md-nav__item">
<a href="#_5" class="md-nav__link">
开发者模式
</a>
</li>
<li class="md-nav__item">
<a href="#docker" class="md-nav__link">
Docker
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-content">
<article class="md-content__inner md-typeset">
<h1>安装说明</h1>
<h2 id="_1">运行环境<a class="headerlink" href="#_1" title="Permanent link">&para;</a></h2>
<p>HttpRunner 是一个基于 Python 开发的测试框架,可以运行在 macOS、Linux、Windows 系统平台上。</p>
<p><strong>Python 版本</strong>HttpRunner 支持 Python 3.4 及以上的所有版本,并使用 Travis-CI 进行了<a href="https://travis-ci.org/HttpRunner/HttpRunner">持续集成测试</a>,测试覆盖的版本包括 2.7/3.4/3.5/3.6/3.7。虽然 HttpRunner 暂时保留了对 Python 2.7 的兼容支持,但强烈建议使用 Python 3.4 及以上版本。</p>
<p><strong>操作系统</strong>:推荐使用 macOS/Linux。</p>
<h2 id="_2">安装方式<a class="headerlink" href="#_2" title="Permanent link">&para;</a></h2>
<p>HttpRunner 的稳定版本托管在 PyPI 上,可以使用 <code>pip</code> 进行安装。</p>
<div class="codehilite"><pre><span></span>$ pip install httprunner
</pre></div>
<p>如果你需要使用最新的开发版本,那么可以采用项目的 GitHub 仓库地址进行安装:</p>
<div class="codehilite"><pre><span></span>$ pip install git+https://github.com/HttpRunner/HttpRunner.git@master
</pre></div>
<h2 id="_3">版本升级<a class="headerlink" href="#_3" title="Permanent link">&para;</a></h2>
<p>假如你之前已经安装过了 HttpRunner现在需要升级到最新版本那么你可以使用<code>-U</code>参数。该参数对以上三种安装方式均生效。</p>
<div class="codehilite"><pre><span></span>$ pip install -U HttpRunner
$ pip install -U git+https://github.com/HttpRunner/HttpRunner.git@master
</pre></div>
<h2 id="_4">安装校验<a class="headerlink" href="#_4" title="Permanent link">&para;</a></h2>
<p>在 HttpRunner 安装成功后,系统中会新增如下 5 个命令:</p>
<ul>
<li><code>httprunner</code>: 核心命令</li>
<li><code>ate</code>: 曾经用过的命令(当时框架名称为 ApiTestEngine功能与 httprunner 完全相同</li>
<li><code>hrun</code>: httprunner 的缩写,功能与 httprunner 完全相同</li>
<li><code>locusts</code>: 基于 <a href="http://locust.io/">Locust</a> 实现<a href="../run-tests/load-test/">性能测试</a></li>
<li><a href="https://github.com/HttpRunner/har2case"><code>har2case</code></a>: 辅助工具,可将标准通用的 HAR 格式HTTP Archive转换为<code>YAML/JSON</code>格式的测试用例</li>
</ul>
<p>httprunner、hrun、ate 三个命令完全等价,功能特性完全相同,个人推荐使用<code>hrun</code>命令。</p>
<p>运行如下命令,若正常显示版本号,则说明 HttpRunner 安装成功。</p>
<div class="codehilite"><pre><span></span>$ hrun -V
2.0.2
$ har2case -V
0.2.0
</pre></div>
<h2 id="_5">开发者模式<a class="headerlink" href="#_5" title="Permanent link">&para;</a></h2>
<p>默认情况下,安装 HttpRunner 的时候只会安装运行 HttpRunner 的必要依赖库。</p>
<p>如果你不仅仅是使用 HttpRunner还需要对 HttpRunner 进行开发调试debug那么就需要进行如下操作。</p>
<p>HttpRunner 使用 <a href="https://docs.pipenv.org/">pipenv</a> 对依赖包进行管理,若你还没有安装 pipenv需要先执行如下命令进行按照</p>
<div class="codehilite"><pre><span></span>$ pip install pipenv
</pre></div>
<p>获取 HttpRunner 源码:</p>
<div class="codehilite"><pre><span></span>$ git clone https://github.com/HttpRunner/HttpRunner.git
</pre></div>
<p>进入仓库目录,安装所有依赖:</p>
<div class="codehilite"><pre><span></span>$ pipenv install --dev
</pre></div>
<p>运行单元测试,若测试全部通过,则说明环境正常。</p>
<div class="codehilite"><pre><span></span>$ pipenv run python -m unittest discover
</pre></div>
<p>查看 HttpRunner 的依赖情况:</p>
<div class="codehilite"><pre><span></span>$ pipenv graph
HttpRunner==2.0.0
- colorama [required: Any, installed: 0.4.0]
- colorlog [required: Any, installed: 3.1.4]
- har2case [required: Any, installed: 0.2.0]
- PyYAML [required: Any, installed: 3.13]
- Jinja2 [required: Any, installed: 2.10]
- MarkupSafe [required: &gt;=0.23, installed: 1.0]
- PyYAML [required: Any, installed: 3.13]
- requests [required: Any, installed: 2.20.0]
- certifi [required: &gt;=2017.4.17, installed: 2018.10.15]
- chardet [required: &gt;=3.0.2,&lt;3.1.0, installed: 3.0.4]
- idna [required: &gt;=2.5,&lt;2.8, installed: 2.7]
- urllib3 [required: &gt;=1.21.1,&lt;1.25, installed: 1.24]
- requests-toolbelt [required: Any, installed: 0.8.0]
- requests [required: &gt;=2.0.1,&lt;3.0.0, installed: 2.20.0]
- certifi [required: &gt;=2017.4.17, installed: 2018.10.15]
- chardet [required: &gt;=3.0.2,&lt;3.1.0, installed: 3.0.4]
- idna [required: &gt;=2.5,&lt;2.8, installed: 2.7]
- urllib3 [required: &gt;=1.21.1,&lt;1.25, installed: 1.24]
</pre></div>
<p>调试运行方式:</p>
<div class="codehilite"><pre><span></span><span class="c1"># 调试运行 hrun</span>
$ pipenv run python main-debug.py hrun -h
<span class="c1"># 调试运行 locusts</span>
$ pipenv run python main-debug.py locusts -h
</pre></div>
<h2 id="docker">Docker<a class="headerlink" href="#docker" title="Permanent link">&para;</a></h2>
<p>TODO</p>
</article>
</div>
</div>
</main>
<footer class="md-footer">
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid">
<a href=".." title="介绍" class="md-flex md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-back md-footer-nav__button"></i>
</div>
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
上一页
</span>
介绍
</span>
</div>
</a>
<a href="../quickstart/" title="快速上手" class="md-flex md-footer-nav__link md-footer-nav__link--next" rel="next">
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
下一页
</span>
快速上手
</span>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-forward md-footer-nav__button"></i>
</div>
</a>
</nav>
</div>
<div class="md-footer-meta md-typeset">
<div class="md-footer-meta__inner md-grid">
<div class="md-footer-copyright">
<div class="md-footer-copyright__highlight">
Copyright &copy; 2017 - 2019 debugtalk
</div>
powered by
<a href="https://www.mkdocs.org">MkDocs</a>
and
<a href="https://squidfunk.github.io/mkdocs-material/">
Material for MkDocs</a>
</div>
<div class="md-footer-social">
<link rel="stylesheet" href="../assets/fonts/font-awesome.css">
<a href="https://debugtalk.com" class="md-footer-social__link fa fa-globe"></a>
<a href="https://github.com/httprunner" class="md-footer-social__link fa fa-github"></a>
</div>
</div>
</div>
</footer>
</div>
<script src="../assets/javascripts/application.ac79c3b0.js"></script>
<script src="../assets/javascripts/lunr/lunr.stemmer.support.js"></script>
<script>app.initialize({version:"1.0.4",url:{base:".."}})</script>
<script src="../js/slardar.js"></script>
</body>
</html>

4
assets/fonts/font-awesome.css vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,13 @@
/*!
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy
* of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING, SOFTWARE
* DISTRIBUTED UNDER THE LICENSE IS DISTRIBUTED ON AN "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
* SEE THE LICENSE FOR THE SPECIFIC LANGUAGE GOVERNING PERMISSIONS AND
* LIMITATIONS UNDER THE LICENSE.
*/@font-face{font-family:"Material Icons";font-style:normal;font-weight:400;src:local("Material Icons"),local("MaterialIcons-Regular"),url("specimen/MaterialIcons-Regular.woff2") format("woff2"),url("specimen/MaterialIcons-Regular.woff") format("woff"),url("specimen/MaterialIcons-Regular.ttf") format("truetype")}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
assets/hogwarts.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

BIN
assets/images/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 521 B

View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="352" height="448" viewBox="0 0 352 448" id="__bitbucket"><path fill="currentColor" d="M203.75 214.75q2 15.75-12.625 25.25t-27.875 1.5q-9.75-4.25-13.375-14.5t-.125-20.5 13-14.5q9-4.5 18.125-3t16 8.875 6.875 16.875zm27.75-5.25q-3.5-26.75-28.25-41T154 165.25q-15.75 7-25.125 22.125t-8.625 32.375q1 22.75 19.375 38.75t41.375 14q22.75-2 38-21t12.5-42zM291.25 74q-5-6.75-14-11.125t-14.5-5.5T245 54.25q-72.75-11.75-141.5.5-10.75 1.75-16.5 3t-13.75 5.5T60.75 74q7.5 7 19 11.375t18.375 5.5T120 93.75Q177 101 232 94q15.75-2 22.375-3t18.125-5.375T291.25 74zm14.25 258.75q-2 6.5-3.875 19.125t-3.5 21-7.125 17.5-14.5 14.125q-21.5 12-47.375 17.875t-50.5 5.5-50.375-4.625q-11.5-2-20.375-4.5T88.75 412 70.5 401.125t-13-15.375q-6.25-24-14.25-73l1.5-4 4.5-2.25q55.75 37 126.625 37t126.875-37q5.25 1.5 6 5.75t-1.25 11.25-2 9.25zM350.75 92.5q-6.5 41.75-27.75 163.75-1.25 7.5-6.75 14t-10.875 10T291.75 288q-63 31.5-152.5 22-62-6.75-98.5-34.75-3.75-3-6.375-6.625t-4.25-8.75-2.25-8.5-1.5-9.875T25 232.75q-2.25-12.5-6.625-37.5t-7-40.375T5.5 118 0 78.5Q.75 72 4.375 66.375T12.25 57t11.25-7.5T35 43.875t12-4.625q31.25-11.5 78.25-16 94.75-9.25 169 12.5Q333 47.25 348 66.25q4 5 4.125 12.75t-1.375 13.5z"/></svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg>

After

Width:  |  Height:  |  Size: 993 B

View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="500" height="500" viewBox="0 0 500 500" id="__gitlab"><path fill="currentColor" d="M93.667 473.347l90.684-279.097H2.983l90.684 279.097z" transform="translate(156.198 1.16)"/><path fill="currentColor" d="M221.333 473.345L130.649 194.25H3.557l217.776 279.095z" transform="translate(28.531 1.16)" opacity=".7"/><path fill="currentColor" d="M32 195.155L4.441 279.97a18.773 18.773 0 0 0 6.821 20.99l238.514 173.29L32 195.155z" transform="translate(.089 .256)" opacity=".5"/><path fill="currentColor" d="M2.667-84.844h127.092L75.14-252.942c-2.811-8.649-15.047-8.649-17.856 0L2.667-84.844z" transform="translate(29.422 280.256)"/><path fill="currentColor" d="M2.667 473.345L93.351 194.25h127.092L2.667 473.345z" transform="translate(247.198 1.16)" opacity=".7"/><path fill="currentColor" d="M221.334 195.155l27.559 84.815a18.772 18.772 0 0 1-6.821 20.99L3.557 474.25l217.777-279.095z" transform="translate(246.307 .256)" opacity=".5"/><path fill="currentColor" d="M130.667-84.844H3.575l54.618-168.098c2.811-8.649 15.047-8.649 17.856 0l54.618 168.098z" transform="translate(336.974 280.256)"/></svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,17 @@
/*!
* Lunr languages, `Danish` language
* https://github.com/MihaiValentin/lunr-languages
*
* Copyright 2014, Mihai Valentin
* http://www.mozilla.org/MPL/
*/
/*!
* based on
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,m,i;e.da=function(){this.pipeline.reset(),this.pipeline.add(e.da.trimmer,e.da.stopWordFilter,e.da.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.da.stemmer))},e.da.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA--",e.da.trimmer=e.trimmerSupport.generateTrimmer(e.da.wordCharacters),e.Pipeline.registerFunction(e.da.trimmer,"trimmer-da"),e.da.stemmer=(r=e.stemmerSupport.Among,m=e.stemmerSupport.SnowballProgram,i=new function(){var i,t,n,s=[new r("hed",-1,1),new r("ethed",0,1),new r("ered",-1,1),new r("e",-1,1),new r("erede",3,1),new r("ende",3,1),new r("erende",5,1),new r("ene",3,1),new r("erne",3,1),new r("ere",3,1),new r("en",-1,1),new r("heden",10,1),new r("eren",10,1),new r("er",-1,1),new r("heder",13,1),new r("erer",13,1),new r("s",-1,2),new r("heds",16,1),new r("es",16,1),new r("endes",18,1),new r("erendes",19,1),new r("enes",18,1),new r("ernes",18,1),new r("eres",18,1),new r("ens",16,1),new r("hedens",24,1),new r("erens",24,1),new r("ers",16,1),new r("ets",16,1),new r("erets",28,1),new r("et",-1,1),new r("eret",30,1)],o=[new r("gd",-1,-1),new r("dt",-1,-1),new r("gt",-1,-1),new r("kt",-1,-1)],a=[new r("ig",-1,1),new r("lig",0,1),new r("elig",1,1),new r("els",-1,1),new r("løst",-1,2)],d=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,48,0,128],u=[239,254,42,3,0,0,0,0,0,0,0,0,0,0,0,0,16],c=new m;function l(){var e,r=c.limit-c.cursor;c.cursor>=t&&(e=c.limit_backward,c.limit_backward=t,c.ket=c.cursor,c.find_among_b(o,4)?(c.bra=c.cursor,c.limit_backward=e,c.cursor=c.limit-r,c.cursor>c.limit_backward&&(c.cursor--,c.bra=c.cursor,c.slice_del())):c.limit_backward=e)}this.setCurrent=function(e){c.setCurrent(e)},this.getCurrent=function(){return c.getCurrent()},this.stem=function(){var e,r=c.cursor;return function(){var e,r=c.cursor+3;if(t=c.limit,0<=r&&r<=c.limit){for(i=r;;){if(e=c.cursor,c.in_grouping(d,97,248)){c.cursor=e;break}if((c.cursor=e)>=c.limit)return;c.cursor++}for(;!c.out_grouping(d,97,248);){if(c.cursor>=c.limit)return;c.cursor++}(t=c.cursor)<i&&(t=i)}}(),c.limit_backward=r,c.cursor=c.limit,function(){var e,r;if(c.cursor>=t&&(r=c.limit_backward,c.limit_backward=t,c.ket=c.cursor,e=c.find_among_b(s,32),c.limit_backward=r,e))switch(c.bra=c.cursor,e){case 1:c.slice_del();break;case 2:c.in_grouping_b(u,97,229)&&c.slice_del()}}(),c.cursor=c.limit,l(),c.cursor=c.limit,function(){var e,r,i,n=c.limit-c.cursor;if(c.ket=c.cursor,c.eq_s_b(2,"st")&&(c.bra=c.cursor,c.eq_s_b(2,"ig")&&c.slice_del()),c.cursor=c.limit-n,c.cursor>=t&&(r=c.limit_backward,c.limit_backward=t,c.ket=c.cursor,e=c.find_among_b(a,5),c.limit_backward=r,e))switch(c.bra=c.cursor,e){case 1:c.slice_del(),i=c.limit-c.cursor,l(),c.cursor=c.limit-i;break;case 2:c.slice_from("løs")}}(),c.cursor=c.limit,c.cursor>=t&&(e=c.limit_backward,c.limit_backward=t,c.ket=c.cursor,c.out_grouping_b(d,97,248)?(c.bra=c.cursor,n=c.slice_to(n),c.limit_backward=e,c.eq_v_b(n)&&c.slice_del()):c.limit_backward=e),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}),e.Pipeline.registerFunction(e.da.stemmer,"stemmer-da"),e.da.stopWordFilter=e.generateStopWordFilter("ad af alle alt anden at blev blive bliver da de dem den denne der deres det dette dig din disse dog du efter eller en end er et for fra ham han hans har havde have hende hendes her hos hun hvad hvis hvor i ikke ind jeg jer jo kunne man mange med meget men mig min mine mit mod ned noget nogle nu når og også om op os over på selv sig sin sine sit skal skulle som sådan thi til ud under var vi vil ville vor være været".split(" ")),e.Pipeline.registerFunction(e.da.stopWordFilter,"stopWordFilter-da")}});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,17 @@
/*!
* Lunr languages, `Japanese` language
* https://github.com/MihaiValentin/lunr-languages
*
* Copyright 2014, Chad Liu
* http://www.mozilla.org/MPL/
*/
/*!
* based on
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(m){if(void 0===m)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===m.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var l="2"==m.version[0];m.ja=function(){this.pipeline.reset(),this.pipeline.add(m.ja.trimmer,m.ja.stopWordFilter,m.ja.stemmer),l?this.tokenizer=m.ja.tokenizer:(m.tokenizer&&(m.tokenizer=m.ja.tokenizer),this.tokenizerFn&&(this.tokenizerFn=m.ja.tokenizer))};var j=new m.TinySegmenter;m.ja.tokenizer=function(e){var r,t,i,n,o,s,p,a,u;if(!arguments.length||null==e||null==e)return[];if(Array.isArray(e))return e.map(function(e){return l?new m.Token(e.toLowerCase()):e.toLowerCase()});for(r=(t=e.toString().toLowerCase().replace(/^\s+/,"")).length-1;0<=r;r--)if(/\S/.test(t.charAt(r))){t=t.substring(0,r+1);break}for(o=[],i=t.length,p=a=0;a<=i;a++)if(s=a-p,t.charAt(a).match(/\s/)||a==i){if(0<s)for(n=j.segment(t.slice(p,a)).filter(function(e){return!!e}),u=p,r=0;r<n.length;r++)l?o.push(new m.Token(n[r],{position:[u,n[r].length],index:o.length})):o.push(n[r]),u+=n[r].length;p=a+1}return o},m.ja.stemmer=function(e){return e},m.Pipeline.registerFunction(m.ja.stemmer,"stemmer-ja"),m.ja.wordCharacters="一二三四五六七八九十百千万億兆一-龠々〆ヵヶぁ-んァ-ヴーア-ン゙a-zA-Z--0-9-",m.ja.trimmer=m.trimmerSupport.generateTrimmer(m.ja.wordCharacters),m.Pipeline.registerFunction(m.ja.trimmer,"trimmer-ja"),m.ja.stopWordFilter=m.generateStopWordFilter("これ それ あれ この その あの ここ そこ あそこ こちら どこ だれ なに なん 何 私 貴方 貴方方 我々 私達 あの人 あのかた 彼女 彼 です あります おります います は が の に を で え から まで より も どの と し それで しかし".split(" ")),m.Pipeline.registerFunction(m.ja.stopWordFilter,"stopWordFilter-ja"),m.jp=m.ja,m.Pipeline.registerFunction(m.jp.stemmer,"stemmer-jp"),m.Pipeline.registerFunction(m.jp.trimmer,"trimmer-jp"),m.Pipeline.registerFunction(m.jp.stopWordFilter,"stopWordFilter-jp")}});

View File

@ -0,0 +1 @@
module.exports=require("./lunr.ja");

View File

@ -0,0 +1 @@
!function(e,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():t()(e.lunr)}(this,function(){return function(o){o.multiLanguage=function(){for(var e=Array.prototype.slice.call(arguments),t=e.join("-"),i="",r=[],n=[],s=0;s<e.length;++s)"en"==e[s]?(i+="\\w",r.unshift(o.stopWordFilter),r.push(o.stemmer),n.push(o.stemmer)):(i+=o[e[s]].wordCharacters,o[e[s]].stopWordFilter&&r.unshift(o[e[s]].stopWordFilter),o[e[s]].stemmer&&(r.push(o[e[s]].stemmer),n.push(o[e[s]].stemmer)));var p=o.trimmerSupport.generateTrimmer(i);return o.Pipeline.registerFunction(p,"lunr-multi-trimmer-"+t),r.unshift(p),function(){this.pipeline.reset(),this.pipeline.add.apply(this.pipeline,r),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add.apply(this.searchPipeline,n))}}}});

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,17 @@
/*!
* Lunr languages, `Norwegian` language
* https://github.com/MihaiValentin/lunr-languages
*
* Copyright 2014, Mihai Valentin
* http://www.mozilla.org/MPL/
*/
/*!
* based on
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,n,i;e.no=function(){this.pipeline.reset(),this.pipeline.add(e.no.trimmer,e.no.stopWordFilter,e.no.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.no.stemmer))},e.no.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA--",e.no.trimmer=e.trimmerSupport.generateTrimmer(e.no.wordCharacters),e.Pipeline.registerFunction(e.no.trimmer,"trimmer-no"),e.no.stemmer=(r=e.stemmerSupport.Among,n=e.stemmerSupport.SnowballProgram,i=new function(){var o,s,a=[new r("a",-1,1),new r("e",-1,1),new r("ede",1,1),new r("ande",1,1),new r("ende",1,1),new r("ane",1,1),new r("ene",1,1),new r("hetene",6,1),new r("erte",1,3),new r("en",-1,1),new r("heten",9,1),new r("ar",-1,1),new r("er",-1,1),new r("heter",12,1),new r("s",-1,2),new r("as",14,1),new r("es",14,1),new r("edes",16,1),new r("endes",16,1),new r("enes",16,1),new r("hetenes",19,1),new r("ens",14,1),new r("hetens",21,1),new r("ers",14,1),new r("ets",14,1),new r("et",-1,1),new r("het",25,1),new r("ert",-1,3),new r("ast",-1,1)],m=[new r("dt",-1,-1),new r("vt",-1,-1)],l=[new r("leg",-1,1),new r("eleg",0,1),new r("ig",-1,1),new r("eig",2,1),new r("lig",2,1),new r("elig",4,1),new r("els",-1,1),new r("lov",-1,1),new r("elov",7,1),new r("slov",7,1),new r("hetslov",9,1)],u=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,48,0,128],d=[119,125,149,1],c=new n;this.setCurrent=function(e){c.setCurrent(e)},this.getCurrent=function(){return c.getCurrent()},this.stem=function(){var e,r,n,i,t=c.cursor;return function(){var e,r=c.cursor+3;if(s=c.limit,0<=r||r<=c.limit){for(o=r;;){if(e=c.cursor,c.in_grouping(u,97,248)){c.cursor=e;break}if(e>=c.limit)return;c.cursor=e+1}for(;!c.out_grouping(u,97,248);){if(c.cursor>=c.limit)return;c.cursor++}(s=c.cursor)<o&&(s=o)}}(),c.limit_backward=t,c.cursor=c.limit,function(){var e,r,n;if(c.cursor>=s&&(r=c.limit_backward,c.limit_backward=s,c.ket=c.cursor,e=c.find_among_b(a,29),c.limit_backward=r,e))switch(c.bra=c.cursor,e){case 1:c.slice_del();break;case 2:n=c.limit-c.cursor,c.in_grouping_b(d,98,122)?c.slice_del():(c.cursor=c.limit-n,c.eq_s_b(1,"k")&&c.out_grouping_b(u,97,248)&&c.slice_del());break;case 3:c.slice_from("er")}}(),c.cursor=c.limit,r=c.limit-c.cursor,c.cursor>=s&&(e=c.limit_backward,c.limit_backward=s,c.ket=c.cursor,c.find_among_b(m,2)?(c.bra=c.cursor,c.limit_backward=e,c.cursor=c.limit-r,c.cursor>c.limit_backward&&(c.cursor--,c.bra=c.cursor,c.slice_del())):c.limit_backward=e),c.cursor=c.limit,c.cursor>=s&&(i=c.limit_backward,c.limit_backward=s,c.ket=c.cursor,(n=c.find_among_b(l,11))?(c.bra=c.cursor,c.limit_backward=i,1==n&&c.slice_del()):c.limit_backward=i),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}),e.Pipeline.registerFunction(e.no.stemmer,"stemmer-no"),e.no.stopWordFilter=e.generateStopWordFilter("alle at av bare begge ble blei bli blir blitt både båe da de deg dei deim deira deires dem den denne der dere deres det dette di din disse ditt du dykk dykkar då eg ein eit eitt eller elles en enn er et ett etter for fordi fra før ha hadde han hans har hennar henne hennes her hjå ho hoe honom hoss hossen hun hva hvem hver hvilke hvilken hvis hvor hvordan hvorfor i ikke ikkje ikkje ingen ingi inkje inn inni ja jeg kan kom korleis korso kun kunne kva kvar kvarhelst kven kvi kvifor man mange me med medan meg meget mellom men mi min mine mitt mot mykje ned no noe noen noka noko nokon nokor nokre nå når og også om opp oss over på samme seg selv si si sia sidan siden sin sine sitt sjøl skal skulle slik so som som somme somt så sånn til um upp ut uten var vart varte ved vere verte vi vil ville vore vors vort vår være være vært å".split(" ")),e.Pipeline.registerFunction(e.no.stopWordFilter,"stopWordFilter-no")}});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,9 @@
/*!
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(r,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():t()(r.lunr)}(this,function(){return function(r){r.stemmerSupport={Among:function(r,t,i,s){if(this.toCharArray=function(r){for(var t=r.length,i=new Array(t),s=0;s<t;s++)i[s]=r.charCodeAt(s);return i},!r&&""!=r||!t&&0!=t||!i)throw"Bad Among initialisation: s:"+r+", substring_i: "+t+", result: "+i;this.s_size=r.length,this.s=this.toCharArray(r),this.substring_i=t,this.result=i,this.method=s},SnowballProgram:function(){var b;return{bra:0,ket:0,limit:0,cursor:0,limit_backward:0,setCurrent:function(r){b=r,this.cursor=0,this.limit=r.length,this.limit_backward=0,this.bra=this.cursor,this.ket=this.limit},getCurrent:function(){var r=b;return b=null,r},in_grouping:function(r,t,i){if(this.cursor<this.limit){var s=b.charCodeAt(this.cursor);if(s<=i&&t<=s&&r[(s-=t)>>3]&1<<(7&s))return this.cursor++,!0}return!1},in_grouping_b:function(r,t,i){if(this.cursor>this.limit_backward){var s=b.charCodeAt(this.cursor-1);if(s<=i&&t<=s&&r[(s-=t)>>3]&1<<(7&s))return this.cursor--,!0}return!1},out_grouping:function(r,t,i){if(this.cursor<this.limit){var s=b.charCodeAt(this.cursor);if(i<s||s<t)return this.cursor++,!0;if(!(r[(s-=t)>>3]&1<<(7&s)))return this.cursor++,!0}return!1},out_grouping_b:function(r,t,i){if(this.cursor>this.limit_backward){var s=b.charCodeAt(this.cursor-1);if(i<s||s<t)return this.cursor--,!0;if(!(r[(s-=t)>>3]&1<<(7&s)))return this.cursor--,!0}return!1},eq_s:function(r,t){if(this.limit-this.cursor<r)return!1;for(var i=0;i<r;i++)if(b.charCodeAt(this.cursor+i)!=t.charCodeAt(i))return!1;return this.cursor+=r,!0},eq_s_b:function(r,t){if(this.cursor-this.limit_backward<r)return!1;for(var i=0;i<r;i++)if(b.charCodeAt(this.cursor-r+i)!=t.charCodeAt(i))return!1;return this.cursor-=r,!0},find_among:function(r,t){for(var i=0,s=t,e=this.cursor,n=this.limit,u=0,o=0,h=!1;;){for(var c=i+(s-i>>1),a=0,f=u<o?u:o,l=r[c],_=f;_<l.s_size;_++){if(e+f==n){a=-1;break}if(a=b.charCodeAt(e+f)-l.s[_])break;f++}if(a<0?(s=c,o=f):(i=c,u=f),s-i<=1){if(0<i||s==i||h)break;h=!0}}for(;;){if(u>=(l=r[i]).s_size){if(this.cursor=e+l.s_size,!l.method)return l.result;var m=l.method();if(this.cursor=e+l.s_size,m)return l.result}if((i=l.substring_i)<0)return 0}},find_among_b:function(r,t){for(var i=0,s=t,e=this.cursor,n=this.limit_backward,u=0,o=0,h=!1;;){for(var c=i+(s-i>>1),a=0,f=u<o?u:o,l=(_=r[c]).s_size-1-f;0<=l;l--){if(e-f==n){a=-1;break}if(a=b.charCodeAt(e-1-f)-_.s[l])break;f++}if(a<0?(s=c,o=f):(i=c,u=f),s-i<=1){if(0<i||s==i||h)break;h=!0}}for(;;){var _;if(u>=(_=r[i]).s_size){if(this.cursor=e-_.s_size,!_.method)return _.result;var m=_.method();if(this.cursor=e-_.s_size,m)return _.result}if((i=_.substring_i)<0)return 0}},replace_s:function(r,t,i){var s=i.length-(t-r);return b=b.substring(0,r)+i+b.substring(t),this.limit+=s,this.cursor>=t?this.cursor+=s:this.cursor>r&&(this.cursor=r),s},slice_check:function(){if(this.bra<0||this.bra>this.ket||this.ket>this.limit||this.limit>b.length)throw"faulty slice operation"},slice_from:function(r){this.slice_check(),this.replace_s(this.bra,this.ket,r)},slice_del:function(){this.slice_from("")},insert:function(r,t,i){var s=this.replace_s(r,t,i);r<=this.bra&&(this.bra+=s),r<=this.ket&&(this.ket+=s)},slice_to:function(){return this.slice_check(),b.substring(this.bra,this.ket)},eq_v_b:function(r){return this.eq_s_b(r.length,r)}}}},r.trimmerSupport={generateTrimmer:function(r){var t=new RegExp("^[^"+r+"]+"),i=new RegExp("[^"+r+"]+$");return function(r){return"function"==typeof r.update?r.update(function(r){return r.replace(t,"").replace(i,"")}):r.replace(t,"").replace(i,"")}}}}});

View File

@ -0,0 +1,17 @@
/*!
* Lunr languages, `Swedish` language
* https://github.com/MihaiValentin/lunr-languages
*
* Copyright 2014, Mihai Valentin
* http://www.mozilla.org/MPL/
*/
/*!
* based on
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,l,n;e.sv=function(){this.pipeline.reset(),this.pipeline.add(e.sv.trimmer,e.sv.stopWordFilter,e.sv.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.sv.stemmer))},e.sv.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA--",e.sv.trimmer=e.trimmerSupport.generateTrimmer(e.sv.wordCharacters),e.Pipeline.registerFunction(e.sv.trimmer,"trimmer-sv"),e.sv.stemmer=(r=e.stemmerSupport.Among,l=e.stemmerSupport.SnowballProgram,n=new function(){var n,t,i=[new r("a",-1,1),new r("arna",0,1),new r("erna",0,1),new r("heterna",2,1),new r("orna",0,1),new r("ad",-1,1),new r("e",-1,1),new r("ade",6,1),new r("ande",6,1),new r("arne",6,1),new r("are",6,1),new r("aste",6,1),new r("en",-1,1),new r("anden",12,1),new r("aren",12,1),new r("heten",12,1),new r("ern",-1,1),new r("ar",-1,1),new r("er",-1,1),new r("heter",18,1),new r("or",-1,1),new r("s",-1,2),new r("as",21,1),new r("arnas",22,1),new r("ernas",22,1),new r("ornas",22,1),new r("es",21,1),new r("ades",26,1),new r("andes",26,1),new r("ens",21,1),new r("arens",29,1),new r("hetens",29,1),new r("erns",21,1),new r("at",-1,1),new r("andet",-1,1),new r("het",-1,1),new r("ast",-1,1)],s=[new r("dd",-1,-1),new r("gd",-1,-1),new r("nn",-1,-1),new r("dt",-1,-1),new r("gt",-1,-1),new r("kt",-1,-1),new r("tt",-1,-1)],a=[new r("ig",-1,1),new r("lig",0,1),new r("els",-1,1),new r("fullt",-1,3),new r("löst",-1,2)],o=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,24,0,32],u=[119,127,149],m=new l;this.setCurrent=function(e){m.setCurrent(e)},this.getCurrent=function(){return m.getCurrent()},this.stem=function(){var e,r=m.cursor;return function(){var e,r=m.cursor+3;if(t=m.limit,0<=r||r<=m.limit){for(n=r;;){if(e=m.cursor,m.in_grouping(o,97,246)){m.cursor=e;break}if(m.cursor=e,m.cursor>=m.limit)return;m.cursor++}for(;!m.out_grouping(o,97,246);){if(m.cursor>=m.limit)return;m.cursor++}(t=m.cursor)<n&&(t=n)}}(),m.limit_backward=r,m.cursor=m.limit,function(){var e,r=m.limit_backward;if(m.cursor>=t&&(m.limit_backward=t,m.cursor=m.limit,m.ket=m.cursor,e=m.find_among_b(i,37),m.limit_backward=r,e))switch(m.bra=m.cursor,e){case 1:m.slice_del();break;case 2:m.in_grouping_b(u,98,121)&&m.slice_del()}}(),m.cursor=m.limit,e=m.limit_backward,m.cursor>=t&&(m.limit_backward=t,m.cursor=m.limit,m.find_among_b(s,7)&&(m.cursor=m.limit,m.ket=m.cursor,m.cursor>m.limit_backward&&(m.bra=--m.cursor,m.slice_del())),m.limit_backward=e),m.cursor=m.limit,function(){var e,r;if(m.cursor>=t){if(r=m.limit_backward,m.limit_backward=t,m.cursor=m.limit,m.ket=m.cursor,e=m.find_among_b(a,5))switch(m.bra=m.cursor,e){case 1:m.slice_del();break;case 2:m.slice_from("lös");break;case 3:m.slice_from("full")}m.limit_backward=r}}(),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return n.setCurrent(e),n.stem(),n.getCurrent()}):(n.setCurrent(e),n.stem(),n.getCurrent())}),e.Pipeline.registerFunction(e.sv.stemmer,"stemmer-sv"),e.sv.stopWordFilter=e.generateStopWordFilter("alla allt att av blev bli blir blivit de dem den denna deras dess dessa det detta dig din dina ditt du där då efter ej eller en er era ert ett från för ha hade han hans har henne hennes hon honom hur här i icke ingen inom inte jag ju kan kunde man med mellan men mig min mina mitt mot mycket ni nu när någon något några och om oss på samma sedan sig sin sina sitta själv skulle som så sådan sådana sådant till under upp ut utan vad var vara varför varit varje vars vart vem vi vid vilka vilkas vilken vilket vår våra vårt än är åt över".split(" ")),e.Pipeline.registerFunction(e.sv.stopWordFilter,"stopWordFilter-sv")}});

View File

@ -0,0 +1,17 @@
/*!
* Lunr languages, `Thai` language
* https://github.com/MihaiValentin/lunr-languages
*
* Copyright 2017, Keerati Thiwanruk
* http://www.mozilla.org/MPL/
*/
/*!
* based on
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(t){if(void 0===t)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===t.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var i="2"==t.version[0];t.th=function(){this.pipeline.reset(),this.pipeline.add(t.th.trimmer),i?this.tokenizer=t.th.tokenizer:(t.tokenizer&&(t.tokenizer=t.th.tokenizer),this.tokenizerFn&&(this.tokenizerFn=t.th.tokenizer))},t.th.wordCharacters="[฀-๿]",t.th.trimmer=t.trimmerSupport.generateTrimmer(t.th.wordCharacters),t.Pipeline.registerFunction(t.th.trimmer,"trimmer-th");var n=t.wordcut;n.init(),t.th.tokenizer=function(e){if(!arguments.length||null==e||null==e)return[];if(Array.isArray(e))return e.map(function(e){return i?new t.Token(e):e});var r=e.toString().replace(/^\s+/,"");return n.cut(r).split("|")}}});

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,17 @@
/*!
* Lunr languages, `Vietnamese` language
* https://github.com/MihaiValentin/lunr-languages
*
* Copyright 2017, Keerati Thiwanruk
* http://www.mozilla.org/MPL/
*/
/*!
* based on
* Snowball JavaScript Library v0.3
* http://code.google.com/p/urim/
* http://snowball.tartarus.org/
*
* Copyright 2010, Oleg Mazko
* http://www.mozilla.org/MPL/
*/
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");e.vi=function(){this.pipeline.reset(),this.pipeline.add(e.vi.stopWordFilter,e.vi.trimmer)},e.vi.wordCharacters="[A-Za-ẓ̀͐́͑̉̃̓ÂâÊêÔôĂ-ăĐ-đƠ-ơƯ-ư]",e.vi.trimmer=e.trimmerSupport.generateTrimmer(e.vi.wordCharacters),e.Pipeline.registerFunction(e.vi.trimmer,"trimmer-vi"),e.vi.stopWordFilter=e.generateStopWordFilter("là cái nhưng mà".split(" "))}});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

BIN
assets/qrcode.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.5 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

Binary file not shown.

917
concept/nominal/index.html Normal file
View File

@ -0,0 +1,917 @@
<!doctype html>
<html lang="zh" class="no-js">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="HttpRunner V2.x User Documentation">
<meta name="author" content="debugtalk">
<meta name="lang:clipboard.copy" content="复制">
<meta name="lang:clipboard.copied" content="已复制">
<meta name="lang:search.language" content="jp">
<meta name="lang:search.pipeline.stopwords" content="True">
<meta name="lang:search.pipeline.trimmer" content="True">
<meta name="lang:search.result.none" content="没有找到符合条件的结果">
<meta name="lang:search.result.one" content="找到 1 个符合条件的结果">
<meta name="lang:search.result.other" content="# 个符合条件的结果">
<meta name="lang:search.tokenizer" content="[\uff0c\u3002]+">
<link rel="shortcut icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.0.4, mkdocs-material-4.4.3">
<title>名词解释 - HttpRunner V2.x 中文使用文档</title>
<link rel="stylesheet" href="../../assets/stylesheets/application.30686662.css">
<link rel="stylesheet" href="../../assets/stylesheets/application-palette.a8b3c06d.css">
<meta name="theme-color" content="#3f51b5">
<script src="../../assets/javascripts/modernizr.74668098.js"></script>
<link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono&display=fallback">
<style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style>
<link rel="stylesheet" href="../../assets/fonts/material-icons.css">
<script>
window.ga = window.ga || function() {
(ga.q = ga.q || []).push(arguments)
}
ga.l = +new Date
/* Setup integration and send page view */
ga("create", "UA-114587036-2", "auto")
ga("set", "anonymizeIp", true)
ga("send", "pageview")
/* Register handler to log search on blur */
document.addEventListener("DOMContentLoaded", () => {
if (document.forms.search) {
var query = document.forms.search.query
query.addEventListener("blur", function() {
if (this.value) {
var path = document.location.pathname;
ga("send", "pageview", path + "?q=" + this.value)
}
})
}
})
</script>
<script async src="https://www.google-analytics.com/analytics.js"></script>
</head>
<body dir="ltr" data-md-color-primary="indigo" data-md-color-accent="indigo">
<svg class="md-svg">
<defs>
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg>
</defs>
</svg>
<input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
<input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
<label class="md-overlay" data-md-component="overlay" for="__drawer"></label>
<a href="#testcase" tabindex="1" class="md-skip">
跳转至
</a>
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<div class="md-flex">
<div class="md-flex__cell md-flex__cell--shrink">
<a href="../.." title="HttpRunner V2.x 中文使用文档" class="md-header-nav__button md-logo">
<i class="md-icon"></i>
</a>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label>
</div>
<div class="md-flex__cell md-flex__cell--stretch">
<div class="md-flex__ellipsis md-header-nav__title" data-md-component="title">
<span class="md-header-nav__topic">
HttpRunner V2.x 中文使用文档
</span>
<span class="md-header-nav__topic">
名词解释
</span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="__search"></label>
<div class="md-search" data-md-component="search" role="dialog">
<label class="md-search__overlay" for="__search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" placeholder="搜索" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active">
<label class="md-icon md-search__icon" for="__search"></label>
<button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1">
&#xE5CD;
</button>
</form>
<div class="md-search__output">
<div class="md-search__scrollwrap" data-md-scrollfix>
<div class="md-search-result" data-md-component="result">
<div class="md-search-result__meta">
键入以开始搜索
</div>
<ol class="md-search-result__list"></ol>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div class="md-header-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
</div>
</div>
</nav>
</header>
<div class="md-container">
<main class="md-main" role="main">
<div class="md-main__inner md-grid" data-md-component="container">
<div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--primary" data-md-level="0">
<label class="md-nav__title md-nav__title--site" for="__drawer">
<a href="../.." title="HttpRunner V2.x 中文使用文档" class="md-nav__button md-logo">
<i class="md-icon"></i>
</a>
HttpRunner V2.x 中文使用文档
</label>
<div class="md-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../.." title="介绍" class="md-nav__link">
介绍
</a>
</li>
<li class="md-nav__item">
<a href="../../Installation/" title="安装说明" class="md-nav__link">
安装说明
</a>
</li>
<li class="md-nav__item">
<a href="../../quickstart/" title="快速上手" class="md-nav__link">
快速上手
</a>
</li>
<li class="md-nav__item md-nav__item--active md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-4" type="checkbox" id="nav-4" checked>
<label class="md-nav__link" for="nav-4">
基础概念
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-4">
基础概念
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item md-nav__item--active">
<input class="md-toggle md-nav__toggle" data-md-toggle="toc" type="checkbox" id="__toc">
<label class="md-nav__link md-nav__link--active" for="__toc">
名词解释
</label>
<a href="./" title="名词解释" class="md-nav__link md-nav__link--active">
名词解释
</a>
<nav class="md-nav md-nav--secondary">
<label class="md-nav__title" for="__toc">目录</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="#testcase" class="md-nav__link">
测试用例testcase
</a>
</li>
<li class="md-nav__item">
<a href="#teststep" class="md-nav__link">
测试步骤teststep
</a>
</li>
<li class="md-nav__item">
<a href="#testsuite" class="md-nav__link">
测试用例集testsuite
</a>
</li>
<li class="md-nav__item">
<a href="#_1" class="md-nav__link">
测试场景
</a>
</li>
<li class="md-nav__item">
<a href="#_2" class="md-nav__link">
项目根目录
</a>
</li>
</ul>
</nav>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-5" type="checkbox" id="nav-5">
<label class="md-nav__link" for="nav-5">
测试准备
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-5">
测试准备
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../prepare/record/" title="录制生成用例" class="md-nav__link">
录制生成用例
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/project-structure/" title="项目文件组织" class="md-nav__link">
项目文件组织
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/testcase-structure/" title="测试用例组织" class="md-nav__link">
测试用例组织
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/request-hook/" title="hook机制" class="md-nav__link">
hook机制
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/dot-env/" title="环境变量" class="md-nav__link">
环境变量
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/testcase-layer/" title="测试用例分层" class="md-nav__link">
测试用例分层
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/parameters/" title="参数化数据驱动" class="md-nav__link">
参数化数据驱动
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/validate-pretty/" title="Validate & Prettify" class="md-nav__link">
Validate & Prettify
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/security/" title="信息安全" class="md-nav__link">
信息安全
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-6" type="checkbox" id="nav-6">
<label class="md-nav__link" for="nav-6">
测试执行
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-6">
测试执行
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../run-tests/cli/" title="运行测试(CLI)" class="md-nav__link">
运行测试(CLI)
</a>
</li>
<li class="md-nav__item">
<a href="../../run-tests/report/" title="测试报告" class="md-nav__link">
测试报告
</a>
</li>
<li class="md-nav__item">
<a href="../../run-tests/load-test/" title="性能测试" class="md-nav__link">
性能测试
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-7" type="checkbox" id="nav-7">
<label class="md-nav__link" for="nav-7">
开发扩展
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-7">
开发扩展
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../development/architecture/" title="Pipline" class="md-nav__link">
Pipline
</a>
</li>
<li class="md-nav__item">
<a href="../../development/dev-api/" title="基础库调用" class="md-nav__link">
基础库调用
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../../FAQ/" title="FAQ" class="md-nav__link">
FAQ
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-9" type="checkbox" id="nav-9">
<label class="md-nav__link" for="nav-9">
实践案例
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-9">
实践案例
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../examples/testerhome-login/" title="TesterHome 登录" class="md-nav__link">
TesterHome 登录
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../../related-docs/" title="相关资料" class="md-nav__link">
相关资料
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-sidebar md-sidebar--secondary" data-md-component="toc">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--secondary">
<label class="md-nav__title" for="__toc">目录</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="#testcase" class="md-nav__link">
测试用例testcase
</a>
</li>
<li class="md-nav__item">
<a href="#teststep" class="md-nav__link">
测试步骤teststep
</a>
</li>
<li class="md-nav__item">
<a href="#testsuite" class="md-nav__link">
测试用例集testsuite
</a>
</li>
<li class="md-nav__item">
<a href="#_1" class="md-nav__link">
测试场景
</a>
</li>
<li class="md-nav__item">
<a href="#_2" class="md-nav__link">
项目根目录
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-content">
<article class="md-content__inner md-typeset">
<h1>名词解释</h1>
<h2 id="testcase">测试用例testcase<a class="headerlink" href="#testcase" title="Permanent link">&para;</a></h2>
<p>从 2.0 版本开始HttpRunner 开始对测试用例的定义进行进一步的明确,参考 <a href="https://en.wikipedia.org/wiki/Test_case">wiki</a> 上的描述。</p>
<blockquote>
<p>A test case is a specification of the inputs, execution conditions, testing procedure, and expected results that define a single test to be executed to achieve a particular software testing objective, such as to exercise a particular program path or to verify compliance with a specific requirement.</p>
</blockquote>
<p>概括下来一条测试用例testcase应该是为了测试某个特定的功能逻辑而精心设计的并且至少包含如下几点</p>
<ul>
<li>明确的测试目的achieve a particular software testing objective</li>
<li>明确的输入inputs</li>
<li>明确的运行环境execution conditions</li>
<li>明确的测试步骤描述testing procedure</li>
<li>明确的预期结果expected results</li>
</ul>
<p>对应地HttpRunner 的测试用例描述方式进行如下设计:</p>
<ul>
<li>测试用例应该是完整且独立的,每条测试用例应该是都可以独立运行的;在 HttpRunner 中,每个 <code>YAML/JSON</code> 文件对应一条测试用例。</li>
<li>测试用例包含 <code>测试脚本</code><code>测试数据</code> 两部分:<ul>
<li><code>测试用例 = 测试脚本 + 测试数据</code></li>
<li><code>测试脚本</code> 重点是描述测试的 <code>业务功能逻辑</code>包括预置条件、测试步骤、预期结果等并且可以结合辅助函数debugtalk.py实现复杂的运算逻辑可以将 <code>测试脚本</code> 理解为编程语言中的 <code>class</code></li>
<li><code>测试数据</code> 重点是对应测试的 <code>业务数据逻辑</code>,可以理解为类的实例化数据;</li>
<li><code>测试数据</code><code>测试脚本</code> 分离后,就可以比较方便地实现数据驱动测试,通过对测试脚本传入一组数据,实现同一业务功能在不同数据逻辑下的测试验证。</li>
</ul>
</li>
</ul>
<h2 id="teststep">测试步骤teststep<a class="headerlink" href="#teststep" title="Permanent link">&para;</a></h2>
<p>测试用例是测试步骤的 <code>有序</code> 集合,而对于接口测试来说,每一个测试步骤应该就对应一个 API 的请求描述。</p>
<h2 id="testsuite">测试用例集testsuite<a class="headerlink" href="#testsuite" title="Permanent link">&para;</a></h2>
<p><code>测试用例集</code><code>测试用例</code><code>无序</code> 集合,集合中的测试用例应该都是相互独立,不存在先后依赖关系的。</p>
<p>如果确实存在先后依赖关系怎么办,例如登录功能和下单功能。正确的做法应该是,在下单测试用例的前置步骤中执行登录操作。</p>
<div class="codehilite"><pre><span></span><span class="p p-Indicator">-</span> <span class="nt">config</span><span class="p">:</span>
<span class="nt">name</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">order product</span>
<span class="p p-Indicator">-</span> <span class="nt">test</span><span class="p">:</span>
<span class="nt">name</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">login</span>
<span class="nt">testcase</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">testcases/login.yml</span>
<span class="p p-Indicator">-</span> <span class="nt">test</span><span class="p">:</span>
<span class="nt">name</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">add to cart</span>
<span class="nt">api</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">api/add_cart.yml</span>
<span class="p p-Indicator">-</span> <span class="nt">test</span><span class="p">:</span>
<span class="nt">name</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">make order</span>
<span class="nt">api</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">api/make_order.yml</span>
</pre></div>
<h2 id="_1">测试场景<a class="headerlink" href="#_1" title="Permanent link">&para;</a></h2>
<p><code>测试场景</code><code>测试用例集</code> 是同一概念,都是 <code>测试用例</code><code>无序</code> 集合。</p>
<ul>
<li>接口</li>
<li>测试用例集</li>
<li>参数</li>
<li>变量</li>
<li>测试脚本YAML/JSON</li>
<li>debugtalk.py</li>
<li>环境变量</li>
</ul>
<h2 id="_2">项目根目录<a class="headerlink" href="#_2" title="Permanent link">&para;</a></h2>
</article>
</div>
</div>
</main>
<footer class="md-footer">
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid">
<a href="../../quickstart/" title="快速上手" class="md-flex md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-back md-footer-nav__button"></i>
</div>
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
上一页
</span>
快速上手
</span>
</div>
</a>
<a href="../../prepare/record/" title="录制生成用例" class="md-flex md-footer-nav__link md-footer-nav__link--next" rel="next">
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
下一页
</span>
录制生成用例
</span>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-forward md-footer-nav__button"></i>
</div>
</a>
</nav>
</div>
<div class="md-footer-meta md-typeset">
<div class="md-footer-meta__inner md-grid">
<div class="md-footer-copyright">
<div class="md-footer-copyright__highlight">
Copyright &copy; 2017 - 2019 debugtalk
</div>
powered by
<a href="https://www.mkdocs.org">MkDocs</a>
and
<a href="https://squidfunk.github.io/mkdocs-material/">
Material for MkDocs</a>
</div>
<div class="md-footer-social">
<link rel="stylesheet" href="../../assets/fonts/font-awesome.css">
<a href="https://debugtalk.com" class="md-footer-social__link fa fa-globe"></a>
<a href="https://github.com/httprunner" class="md-footer-social__link fa fa-github"></a>
</div>
</div>
</div>
</footer>
</div>
<script src="../../assets/javascripts/application.ac79c3b0.js"></script>
<script src="../../assets/javascripts/lunr/lunr.stemmer.support.js"></script>
<script>app.initialize({version:"1.0.4",url:{base:"../.."}})</script>
<script src="../../js/slardar.js"></script>
</body>
</html>

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

4
data/account.csv Normal file
View File

@ -0,0 +1,4 @@
username,password,phone
test1,111111,18600000001
test2,222222,18600000002
test3,333333,18600000003
1 username password phone
2 test1 111111 18600000001
3 test2 222222 18600000002
4 test3 333333 18600000003

223
data/api_server.py Normal file
View File

@ -0,0 +1,223 @@
import hashlib
import hmac
import json
import random
import string
from functools import wraps
from flask import Flask, make_response, request
SECRET_KEY = "DebugTalk"
app = Flask(__name__)
""" storage all users' data
data structure:
users_dict = {
'uid1': {
'name': 'name1',
'password': 'pwd1'
},
'uid2': {
'name': 'name2',
'password': 'pwd2'
}
}
"""
users_dict = {}
""" storage all token data
data structure:
token_dict = {
'device_sn1': 'token1',
'device_sn2': 'token1'
}
"""
token_dict = {}
def gen_random_string(str_len):
""" generate random string with specified length
"""
return ''.join(
random.choice(string.ascii_letters + string.digits) for _ in range(str_len))
def get_sign(*args):
content = ''.join(args).encode('ascii')
sign_key = SECRET_KEY.encode('ascii')
sign = hmac.new(sign_key, content, hashlib.sha1).hexdigest()
return sign
def gen_md5(*args):
return hashlib.md5("".join(args).encode('utf-8')).hexdigest()
def validate_request(func):
@wraps(func)
def wrapper(*args, **kwargs):
device_sn = request.headers.get('device_sn', "")
token = request.headers.get('token', "")
if not device_sn or not token:
result = {
'success': False,
'msg': "device_sn or token is null."
}
response = make_response(json.dumps(result), 401)
response.headers["Content-Type"] = "application/json"
return response
if token_dict.get(device_sn) != token:
result = {
'success': False,
'msg': "Authorization failed!"
}
response = make_response(json.dumps(result), 403)
response.headers["Content-Type"] = "application/json"
return response
return func(*args, **kwargs)
return wrapper
@app.route('/')
def index():
return "Hello World!"
@app.route('/api/get-token', methods=['POST'])
def get_token():
device_sn = request.headers.get('device_sn', "")
os_platform = request.headers.get('os_platform', "")
app_version = request.headers.get('app_version', "")
data = request.get_json()
sign = data.get('sign', "")
expected_sign = get_sign(device_sn, os_platform, app_version)
if expected_sign != sign:
result = {
'success': False,
'msg': "Authorization failed!"
}
response = make_response(json.dumps(result), 403)
else:
token = gen_random_string(16)
token_dict[device_sn] = token
result = {
'success': True,
'token': token
}
response = make_response(json.dumps(result))
response.headers["Content-Type"] = "application/json"
return response
@app.route('/api/users')
@validate_request
def get_users():
users_list = [user for uid, user in users_dict.items()]
users = {
'success': True,
'count': len(users_list),
'items': users_list
}
response = make_response(json.dumps(users))
response.headers["Content-Type"] = "application/json"
return response
@app.route('/api/reset-all')
@validate_request
def clear_users():
users_dict.clear()
result = {
'success': True
}
response = make_response(json.dumps(result))
response.headers["Content-Type"] = "application/json"
return response
@app.route('/api/users/<int:uid>', methods=['POST'])
@validate_request
def create_user(uid):
user = request.get_json()
if uid not in users_dict:
result = {
'success': True,
'msg': "user created successfully."
}
status_code = 201
users_dict[uid] = user
else:
result = {
'success': False,
'msg': "user already existed."
}
status_code = 500
response = make_response(json.dumps(result), status_code)
response.headers["Content-Type"] = "application/json"
return response
@app.route('/api/users/<int:uid>')
@validate_request
def get_user(uid):
user = users_dict.get(uid, {})
if user:
result = {
'success': True,
'data': user
}
status_code = 200
else:
result = {
'success': False,
'data': user
}
status_code = 404
response = make_response(json.dumps(result), status_code)
response.headers["Content-Type"] = "application/json"
return response
@app.route('/api/users/<int:uid>', methods=['PUT'])
@validate_request
def update_user(uid):
user = users_dict.get(uid, {})
if user:
user = request.get_json()
success = True
status_code = 200
users_dict[uid] = user
else:
success = False
status_code = 404
result = {
'success': success,
'data': user
}
response = make_response(json.dumps(result), status_code)
response.headers["Content-Type"] = "application/json"
return response
@app.route('/api/users/<int:uid>', methods=['DELETE'])
@validate_request
def delete_user(uid):
user = users_dict.pop(uid, {})
if user:
success = True
status_code = 200
else:
success = False
status_code = 404
result = {
'success': success,
'data': user
}
response = make_response(json.dumps(result), status_code)
response.headers["Content-Type"] = "application/json"
return response

3
data/app_version.csv Normal file
View File

@ -0,0 +1,3 @@
app_version
2.8.5
2.8.6
1 app_version
2 2.8.5
3 2.8.6

48
data/debugtalk.py Normal file
View File

@ -0,0 +1,48 @@
import hashlib
import hmac
import random
import string
import time
SECRET_KEY = "DebugTalk"
def gen_random_string(str_len):
random_char_list = []
for _ in range(str_len):
random_char = random.choice(string.ascii_letters + string.digits)
random_char_list.append(random_char)
random_string = ''.join(random_char_list)
return random_string
def get_sign(*args):
content = ''.join(args).encode('ascii')
sign_key = SECRET_KEY.encode('ascii')
sign = hmac.new(sign_key, content, hashlib.sha1).hexdigest()
return sign
def gen_user_id():
return int(time.time() * 1000)
def get_user_id():
return [
{"user_id": 1001},
{"user_id": 1002},
{"user_id": 1003},
{"user_id": 1004}
]
def get_account(num):
accounts = []
for index in range(1, num+1):
accounts.append(
{"username": "user%s" % index, "password": str(index) * 6},
)
return accounts
def get_os_platform():
return [
{"os_platform": "ios"},
{"os_platform": "android"}
]

View File

@ -0,0 +1,10 @@
config:
name: get token with parameters
testcases:
get token with $user_agent, $app_version, $os_platform:
testcase: demo-testcase-get-token.yml
parameters:
user_agent: ["iOS/10.1", "iOS/10.2", "iOS/10.3"]
app_version: ${P(app_version.csv)}
os_platform: ${get_os_platform()}

View File

@ -0,0 +1,58 @@
[
{
"config": {
"name": "testcase description",
"variables": {}
}
},
{
"test": {
"name": "/api/get-token",
"request": {
"url": "http://127.0.0.1:5000/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"os_platform": "ios",
"app_version": "2.8.6",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.token", "baNLX1zhFYP11Seb"]}
]
}
},
{
"test": {
"name": "/api/users/1000",
"request": {
"url": "http://127.0.0.1:5000/api/users/1000",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"token": "baNLX1zhFYP11Seb",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,41 @@
- config:
name: testcase description
variables: {}
- test:
name: /api/get-token
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: 2.8.6
device_sn: FwgRiO7CNA50DSU
os_platform: ios
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: http://127.0.0.1:5000/api/get-token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.token, baNLX1zhFYP11Seb]
- test:
name: /api/users/1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: FwgRiO7CNA50DSU
token: baNLX1zhFYP11Seb
json:
name: user1
password: '123456'
method: POST
url: http://127.0.0.1:5000/api/users/1000
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,57 @@
[
{
"config": {
"name": "testcase description",
"variables": {}
}
},
{
"test": {
"name": "/api/get-token",
"request": {
"url": "http://127.0.0.1:5000/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"os_platform": "ios",
"app_version": "2.8.6",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]}
]
}
},
{
"test": {
"name": "/api/users/1000",
"request": {
"url": "http://127.0.0.1:5000/api/users/1000",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"token": "baNLX1zhFYP11Seb",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,40 @@
- config:
name: testcase description
variables: {}
- test:
name: /api/get-token
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: 2.8.6
device_sn: FwgRiO7CNA50DSU
os_platform: ios
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: http://127.0.0.1:5000/api/get-token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- test:
name: /api/users/1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: FwgRiO7CNA50DSU
token: baNLX1zhFYP11Seb
json:
name: user1
password: '123456'
method: POST
url: http://127.0.0.1:5000/api/users/1000
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,60 @@
[
{
"config": {
"name": "testcase description",
"variables": {}
}
},
{
"test": {
"name": "/api/get-token",
"request": {
"url": "http://127.0.0.1:5000/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"os_platform": "ios",
"app_version": "2.8.6",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"extract": [
{"token": "content.token"}
],
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]}
]
}
},
{
"test": {
"name": "/api/users/1000",
"request": {
"url": "http://127.0.0.1:5000/api/users/1000",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"token": "$token",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,42 @@
- config:
name: testcase description
variables: {}
- test:
name: /api/get-token
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: 2.8.6
device_sn: FwgRiO7CNA50DSU
os_platform: ios
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: http://127.0.0.1:5000/api/get-token
extract:
token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- test:
name: /api/users/1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: FwgRiO7CNA50DSU
token: $token
json:
name: user1
password: '123456'
method: POST
url: http://127.0.0.1:5000/api/users/1000
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,61 @@
[
{
"config": {
"name": "testcase description",
"base_url": "http://127.0.0.1:5000",
"variables": {}
}
},
{
"test": {
"name": "/api/get-token",
"request": {
"url": "/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"os_platform": "ios",
"app_version": "2.8.6",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"extract": [
{"token": "content.token"}
],
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]}
]
}
},
{
"test": {
"name": "/api/users/1000",
"request": {
"url": "/api/users/1000",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"token": "$token",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,43 @@
- config:
name: testcase description
base_url: http://127.0.0.1:5000
variables: {}
- test:
name: /api/get-token
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: 2.8.6
device_sn: FwgRiO7CNA50DSU
os_platform: ios
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: /api/get-token
extract:
token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- test:
name: /api/users/1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: FwgRiO7CNA50DSU
token: $token
json:
name: user1
password: '123456'
method: POST
url: /api/users/1000
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,70 @@
[
{
"config": {
"name": "testcase description",
"base_url": "http://127.0.0.1:5000",
"variables": {}
}
},
{
"test": {
"name": "/api/get-token",
"variables": {
"device_sn": "FwgRiO7CNA50DSU",
"os_platform": "ios",
"app_version": "2.8.6"
},
"request": {
"url": "/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "$device_sn",
"os_platform": "$os_platform",
"app_version": "$app_version",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"extract": [
{"token": "content.token"}
],
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]}
]
}
},
{
"test": {
"name": "/api/users/$user_id",
"variables": {
"device_sn": "FwgRiO7CNA50DSU",
"user_id": "1000"
},
"request": {
"url": "/api/users/$user_id",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "$device_sn",
"token": "$token",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,50 @@
- config:
name: testcase description
base_url: http://127.0.0.1:5000
variables: {}
- test:
name: /api/get-token
variables:
app_version: 2.8.6
device_sn: FwgRiO7CNA50DSU
os_platform: ios
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: $app_version
device_sn: $device_sn
os_platform: $os_platform
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: /api/get-token
extract:
token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- test:
name: /api/users/$user_id
variables:
device_sn: FwgRiO7CNA50DSU
user_id: 1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: $device_sn
token: $token
json:
name: user1
password: '123456'
method: POST
url: /api/users/$user_id
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,70 @@
[
{
"config": {
"name": "testcase description",
"base_url": "http://127.0.0.1:5000",
"variables": {
"device_sn": "FwgRiO7CNA50DSU"
}
}
},
{
"test": {
"name": "/api/get-token",
"variables": {
"os_platform": "ios",
"app_version": "2.8.6"
},
"request": {
"url": "/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "$device_sn",
"os_platform": "$os_platform",
"app_version": "$app_version",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"extract": [
{"token": "content.token"}
],
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]}
]
}
},
{
"test": {
"name": "/api/users/$user_id",
"variables": {
"user_id": "1000"
},
"request": {
"url": "/api/users/$user_id",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "$device_sn",
"token": "$token",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,49 @@
- config:
name: testcase description
base_url: http://127.0.0.1:5000
variables:
device_sn: FwgRiO7CNA50DSU
- test:
name: /api/get-token
variables:
app_version: 2.8.6
os_platform: ios
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: $app_version
device_sn: $device_sn
os_platform: $os_platform
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: /api/get-token
extract:
token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- test:
name: /api/users/$user_id
variables:
user_id: 1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: $device_sn
token: $token
json:
name: user1
password: '123456'
method: POST
url: /api/users/$user_id
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,70 @@
[
{
"config": {
"name": "testcase description",
"base_url": "http://127.0.0.1:5000",
"variables": {
"device_sn": "${gen_random_string(15)}"
}
}
},
{
"test": {
"name": "/api/get-token",
"variables": {
"os_platform": "ios",
"app_version": "2.8.6"
},
"request": {
"url": "/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "$device_sn",
"os_platform": "$os_platform",
"app_version": "$app_version",
"Content-Type": "application/json"
},
"json": {
"sign": "${get_sign($device_sn, $os_platform, $app_version)}"
}
},
"extract": [
{"token": "content.token"}
],
"validate": [
{"eq": ["status_code", 200]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]}
]
}
},
{
"test": {
"name": "/api/users/$user_id",
"variables": {
"user_id": "${gen_user_id()}"
},
"request": {
"url": "/api/users/$user_id",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "$device_sn",
"token": "$token",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{"eq": ["status_code", 201]},
{"eq": ["headers.Content-Type", "application/json"]},
{"eq": ["content.success", true]},
{"eq": ["content.msg", "user created successfully."]}
]
}
}
]

View File

@ -0,0 +1,49 @@
- config:
name: testcase description
base_url: http://127.0.0.1:5000
variables:
device_sn: ${gen_random_string(15)}
- test:
name: /api/get-token
variables:
app_version: 2.8.6
os_platform: ios
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: $app_version
device_sn: $device_sn
os_platform: $os_platform
json:
sign: ${get_sign($device_sn, $os_platform, $app_version)}
method: POST
url: /api/get-token
extract:
token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- test:
name: /api/users/$user_id
variables:
user_id: ${gen_user_id()}
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: $device_sn
token: $token
json:
name: user1
password: '123456'
method: POST
url: /api/users/$user_id
validate:
- eq: [status_code, 201]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]
- eq: [content.msg, user created successfully.]

View File

@ -0,0 +1,13 @@
{
"config": {
"name": "create users with parameters"
},
"testcases": {
"create user $user_id": {
"testcase": "demo-quickstart-6.yml",
"parameters": {
"user_id": [1001, 1002, 1003, 1004]
}
}
}
}

View File

@ -0,0 +1,8 @@
config:
name: testcase description
testcases:
create user $user_id:
testcase: demo-quickstart-6.yml
parameters:
user_id: [1001, 1002, 1003, 1004]

221
data/demo-quickstart.har Normal file
View File

@ -0,0 +1,221 @@
{
"log": {
"version": "1.2",
"creator": {
"name": "Charles Proxy",
"version": "4.2.1"
},
"entries": [
{
"startedDateTime": "2018-02-19T17:30:00.904+08:00",
"time": 3,
"request": {
"method": "POST",
"url": "http://127.0.0.1:5000/api/get-token",
"httpVersion": "HTTP/1.1",
"cookies": [],
"headers": [
{
"name": "Host",
"value": "127.0.0.1:5000"
},
{
"name": "User-Agent",
"value": "python-requests/2.18.4"
},
{
"name": "Accept-Encoding",
"value": "gzip, deflate"
},
{
"name": "Accept",
"value": "*/*"
},
{
"name": "Connection",
"value": "keep-alive"
},
{
"name": "device_sn",
"value": "FwgRiO7CNA50DSU"
},
{
"name": "os_platform",
"value": "ios"
},
{
"name": "app_version",
"value": "2.8.6"
},
{
"name": "Content-Length",
"value": "52"
},
{
"name": "Content-Type",
"value": "application/json"
}
],
"queryString": [],
"postData": {
"mimeType": "application/json",
"text": "{\"sign\": \"9c0c7e51c91ae963c833a4ccbab8d683c4a90c98\"}"
},
"headersSize": 299,
"bodySize": 52
},
"response": {
"_charlesStatus": "COMPLETE",
"status": 200,
"statusText": "OK",
"httpVersion": "HTTP/1.0",
"cookies": [],
"headers": [
{
"name": "Content-Type",
"value": "application/json"
},
{
"name": "Content-Length",
"value": "46"
},
{
"name": "Server",
"value": "Werkzeug/0.14.1 Python/3.6.4"
},
{
"name": "Date",
"value": "Mon, 19 Feb 2018 09:30:00 GMT"
},
{
"name": "Proxy-Connection",
"value": "Close"
}
],
"content": {
"size": 46,
"mimeType": "application/json",
"text": "eyJzdWNjZXNzIjogdHJ1ZSwgInRva2VuIjogImJhTkxYMXpoRllQMTFTZWIifQ==",
"encoding": "base64"
},
"redirectURL": null,
"headersSize": 175,
"bodySize": 46
},
"serverIPAddress": "127.0.0.1",
"cache": {},
"timings": {
"dns": 1,
"connect": 0,
"ssl": -1,
"send": 0,
"wait": 1,
"receive": 1
}
},
{
"startedDateTime": "2018-02-19T17:30:00.911+08:00",
"time": 3,
"request": {
"method": "POST",
"url": "http://127.0.0.1:5000/api/users/1000",
"httpVersion": "HTTP/1.1",
"cookies": [],
"headers": [
{
"name": "Host",
"value": "127.0.0.1:5000"
},
{
"name": "User-Agent",
"value": "python-requests/2.18.4"
},
{
"name": "Accept-Encoding",
"value": "gzip, deflate"
},
{
"name": "Accept",
"value": "*/*"
},
{
"name": "Connection",
"value": "keep-alive"
},
{
"name": "device_sn",
"value": "FwgRiO7CNA50DSU"
},
{
"name": "token",
"value": "baNLX1zhFYP11Seb"
},
{
"name": "Content-Length",
"value": "39"
},
{
"name": "Content-Type",
"value": "application/json"
}
],
"queryString": [],
"postData": {
"mimeType": "application/json",
"text": "{\"name\": \"user1\", \"password\": \"123456\"}"
},
"headersSize": 265,
"bodySize": 39
},
"response": {
"_charlesStatus": "COMPLETE",
"status": 201,
"statusText": "CREATED",
"httpVersion": "HTTP/1.0",
"cookies": [],
"headers": [
{
"name": "Content-Type",
"value": "application/json"
},
{
"name": "Content-Length",
"value": "54"
},
{
"name": "Server",
"value": "Werkzeug/0.14.1 Python/3.6.4"
},
{
"name": "Date",
"value": "Mon, 19 Feb 2018 09:30:00 GMT"
},
{
"name": "Proxy-Connection",
"value": "Close"
}
],
"content": {
"size": 54,
"mimeType": "application/json",
"text": "eyJzdWNjZXNzIjogdHJ1ZSwgIm1zZyI6ICJ1c2VyIGNyZWF0ZWQgc3VjY2Vzc2Z1bGx5LiJ9",
"encoding": "base64"
},
"redirectURL": null,
"headersSize": 77,
"bodySize": 54
},
"serverIPAddress": "127.0.0.1",
"cache": {},
"timings": {
"dns": 0,
"connect": 0,
"ssl": -1,
"send": 0,
"wait": 3,
"receive": 0
}
}
]
}
}

98
data/demo-quickstart.json Normal file
View File

@ -0,0 +1,98 @@
[
{
"config": {
"name": "testcase description",
"variables": {}
}
},
{
"test": {
"name": "/api/get-token",
"request": {
"url": "http://127.0.0.1:5000/api/get-token",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"os_platform": "ios",
"app_version": "2.8.6",
"Content-Type": "application/json"
},
"json": {
"sign": "9c0c7e51c91ae963c833a4ccbab8d683c4a90c98"
}
},
"validate": [
{
"eq": [
"status_code",
200
]
},
{
"eq": [
"headers.Content-Type",
"application/json"
]
},
{
"eq": [
"content.success",
true
]
},
{
"eq": [
"content.token",
"baNLX1zhFYP11Seb"
]
}
]
}
},
{
"test": {
"name": "/api/users/1000",
"request": {
"url": "http://127.0.0.1:5000/api/users/1000",
"method": "POST",
"headers": {
"User-Agent": "python-requests/2.18.4",
"device_sn": "FwgRiO7CNA50DSU",
"token": "baNLX1zhFYP11Seb",
"Content-Type": "application/json"
},
"json": {
"name": "user1",
"password": "123456"
}
},
"validate": [
{
"eq": [
"status_code",
201
]
},
{
"eq": [
"headers.Content-Type",
"application/json"
]
},
{
"eq": [
"content.success",
true
]
},
{
"eq": [
"content.msg",
"user created successfully."
]
}
]
}
}
]

55
data/demo-quickstart.yml Normal file
View File

@ -0,0 +1,55 @@
- config:
name: testcase description
variables: {}
- test:
name: /api/get-token
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: 2.8.6
device_sn: FwgRiO7CNA50DSU
os_platform: ios
json:
sign: 9c0c7e51c91ae963c833a4ccbab8d683c4a90c98
method: POST
url: http://127.0.0.1:5000/api/get-token
validate:
- eq:
- status_code
- 200
- eq:
- headers.Content-Type
- application/json
- eq:
- content.success
- true
- eq:
- content.token
- baNLX1zhFYP11Seb
- test:
name: /api/users/1000
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
device_sn: FwgRiO7CNA50DSU
token: baNLX1zhFYP11Seb
json:
name: user1
password: '123456'
method: POST
url: http://127.0.0.1:5000/api/users/1000
validate:
- eq:
- status_code
- 201
- eq:
- headers.Content-Type
- application/json
- eq:
- content.success
- true
- eq:
- content.msg
- user created successfully.

View File

@ -0,0 +1,27 @@
- config:
name: get token
base_url: http://127.0.0.1:5000
variables:
device_sn: ${gen_random_string(15)}
os_platform: 'ios'
app_version: '2.8.6'
- test:
name: get token with $device_sn, $os_platform, $app_version
request:
headers:
Content-Type: application/json
User-Agent: python-requests/2.18.4
app_version: $app_version
device_sn: $device_sn
os_platform: $os_platform
json:
sign: ${get_sign($device_sn, $os_platform, $app_version)}
method: POST
url: /api/get-token
extract:
token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]

34
data/demo_parameters.yml Normal file
View File

@ -0,0 +1,34 @@
- config:
name: "user management testcase."
parameters:
- user_agent: ["iOS/10.1", "iOS/10.2", "iOS/10.3"]
- app_version: ${P(app_version.csv)}
- os_platform: ${get_os_platform()}
variables:
- user_agent: 'iOS/10.3'
- device_sn: ${gen_random_string(15)}
- os_platform: 'ios'
- app_version: '2.8.6'
request:
base_url: http://127.0.0.1:5000
headers:
Content-Type: application/json
device_sn: $device_sn
- test:
name: get token with $user_agent, $os_platform, $app_version
request:
url: /api/get-token
method: POST
headers:
app_version: $app_version
os_platform: $os_platform
user_agent: $user_agent
json:
sign: ${get_sign($user_agent, $device_sn, $os_platform, $app_version)}
extract:
- token: content.token
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, application/json]
- eq: [content.success, true]

View File

@ -0,0 +1,115 @@
{
"project_mapping":{
"env":{},
"PWD":"/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner-docs-v2x/docs/data",
"debugtalk.py":"/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner-docs-v2x/docs/data/debugtalk.py",
"test_path":"docs/data/demo-quickstart-6.json"
},
"testcases":[
{
"config":{
"name":"testcase description",
"base_url":"http://127.0.0.1:5000",
"variables":{
"device_sn":"${gen_random_string(15)}"
}
},
"teststeps":[
{
"name":"/api/get-token",
"variables":{
"os_platform":"ios",
"app_version":"2.8.6"
},
"request":{
"url":"/api/get-token",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"device_sn":"$device_sn",
"os_platform":"$os_platform",
"app_version":"$app_version",
"Content-Type":"application/json"
},
"json":{
"sign":"${get_sign($device_sn, $os_platform, $app_version)}"
}
},
"extract":[
{
"token":"content.token"
}
],
"validate":[
{
"eq":[
"status_code",
200
]
},
{
"eq":[
"headers.Content-Type",
"application/json"
]
},
{
"eq":[
"content.success",
true
]
}
]
},
{
"name":"/api/users/$user_id",
"variables":{
"user_id":"${gen_user_id()}"
},
"request":{
"url":"/api/users/$user_id",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"device_sn":"$device_sn",
"token":"$token",
"Content-Type":"application/json"
},
"json":{
"name":"user1",
"password":"123456"
}
},
"validate":[
{
"eq":[
"status_code",
201
]
},
{
"eq":[
"headers.Content-Type",
"application/json"
]
},
{
"eq":[
"content.success",
true
]
},
{
"eq":[
"content.msg",
"user created successfully."
]
}
]
}
],
"path":"/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner-docs-v2x/docs/data/demo-quickstart-6.json",
"type":"testcase"
}
]
}

View File

@ -0,0 +1,115 @@
{
"project_mapping":{
"env":{},
"PWD":"/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner-docs-v2x/docs/data",
"debugtalk.py":"/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner-docs-v2x/docs/data/debugtalk.py",
"test_path":"docs/data/demo-quickstart-6.json"
},
"testcases":[
{
"config":{
"name":"testcase description"
},
"teststeps":[
{
"request":{
"url":"http://127.0.0.1:5000/api/get-token",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"device_sn":"$device_sn",
"os_platform":"$os_platform",
"app_version":"$app_version",
"Content-Type":"application/json"
},
"json":{
"sign":"${get_sign($device_sn, $os_platform, $app_version)}"
}
},
"extract":[
{
"token":"content.token"
}
],
"validate":[
{
"eq":[
"status_code",
200
]
},
{
"eq":[
"headers.Content-Type",
"application/json"
]
},
{
"eq":[
"content.success",
true
]
}
],
"verify":true,
"variables":{
"os_platform":"ios",
"app_version":"2.8.6",
"device_sn":"mmHBimjzK4Pk6mg"
},
"name":"/api/get-token"
},
{
"request":{
"url":"http://127.0.0.1:5000/api/users/1548560768589",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"device_sn":"$device_sn",
"token":"$token",
"Content-Type":"application/json"
},
"json":{
"name":"user1",
"password":"123456"
}
},
"validate":[
{
"eq":[
"status_code",
201
]
},
{
"eq":[
"headers.Content-Type",
"application/json"
]
},
{
"eq":[
"content.success",
true
]
},
{
"eq":[
"content.msg",
"user created successfully."
]
}
],
"verify":true,
"variables":{
"user_id":1548560768589,
"device_sn":"mmHBimjzK4Pk6mg"
},
"name":"/api/users/1548560768589"
}
],
"path":"/Users/debugtalk/MyProjects/HttpRunner-dev/httprunner-docs-v2x/docs/data/demo-quickstart-6.json",
"type":"testcase"
}
]
}

View File

@ -0,0 +1,361 @@
{
"success":true,
"stat":{
"testcases":{
"total":1,
"success":1,
"fail":0
},
"teststeps":{
"total":2,
"failures":0,
"errors":0,
"skipped":0,
"expectedFailures":0,
"unexpectedSuccesses":0,
"successes":2
}
},
"time":{
"start_at":1548560768.590071,
"duration":0.036631107330322266
},
"platform":{
"httprunner_version":"2.0.2",
"python_version":"CPython 3.7.0",
"platform":"Darwin-18.2.0-x86_64-i386-64bit"
},
"details":[
{
"success":true,
"stat":{
"total":2,
"failures":0,
"errors":0,
"skipped":0,
"expectedFailures":0,
"unexpectedSuccesses":0,
"successes":2
},
"time":{
"start_at":1548560768.590071,
"duration":0.036631107330322266
},
"records":[
{
"name":"/api/get-token",
"status":"success",
"attachment":"",
"meta_datas":{
"name":"/api/get-token",
"data":[
{
"request":{
"url":"http://127.0.0.1:5000/api/get-token",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"Accept-Encoding":"gzip, deflate",
"Accept":"*/*",
"Connection":"keep-alive",
"device_sn":"mmHBimjzK4Pk6mg",
"os_platform":"ios",
"app_version":"2.8.6",
"Content-Type":"application/json",
"Content-Length":"52"
},
"body":"{&#34;sign&#34;: &#34;57885427ba4f3d55b6bce51827c5152a0f0f850f&#34;}"
},
"response":{
"ok":true,
"url":"http://127.0.0.1:5000/api/get-token",
"status_code":200,
"reason":"OK",
"cookies":{},
"encoding":"None",
"headers":{
"Content-Type":"application/json",
"Content-Length":"46",
"Server":"Werkzeug/0.14.1 Python/3.6.5+",
"Date":"Sun, 27 Jan 2019 03:46:08 GMT"
},
"content_type":"application/json",
"json":{
"success":true,
"token":"C3olNHYCMWfSQkCW"
}
}
}
],
"stat":{
"response_time_ms":11.42,
"elapsed_ms":3.71,
"content_size":46
},
"validators":[
{
"check":"status_code",
"expect":200,
"comparator":"eq",
"check_value":200,
"check_result":"pass"
},
{
"check":"headers.Content-Type",
"expect":"application/json",
"comparator":"eq",
"check_value":"application/json",
"check_result":"pass"
},
{
"check":"content.success",
"expect":true,
"comparator":"eq",
"check_value":true,
"check_result":"pass"
}
]
},
"meta_datas_expanded":[
{
"name":"/api/get-token",
"data":[
{
"request":{
"url":"http://127.0.0.1:5000/api/get-token",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"Accept-Encoding":"gzip, deflate",
"Accept":"*/*",
"Connection":"keep-alive",
"device_sn":"mmHBimjzK4Pk6mg",
"os_platform":"ios",
"app_version":"2.8.6",
"Content-Type":"application/json",
"Content-Length":"52"
},
"body":"{&#34;sign&#34;: &#34;57885427ba4f3d55b6bce51827c5152a0f0f850f&#34;}"
},
"response":{
"ok":true,
"url":"http://127.0.0.1:5000/api/get-token",
"status_code":200,
"reason":"OK",
"cookies":{},
"encoding":"None",
"headers":{
"Content-Type":"application/json",
"Content-Length":"46",
"Server":"Werkzeug/0.14.1 Python/3.6.5+",
"Date":"Sun, 27 Jan 2019 03:46:08 GMT"
},
"content_type":"application/json",
"json":{
"success":true,
"token":"C3olNHYCMWfSQkCW"
}
}
}
],
"stat":{
"response_time_ms":11.42,
"elapsed_ms":3.71,
"content_size":46
},
"validators":[
{
"check":"status_code",
"expect":200,
"comparator":"eq",
"check_value":200,
"check_result":"pass"
},
{
"check":"headers.Content-Type",
"expect":"application/json",
"comparator":"eq",
"check_value":"application/json",
"check_result":"pass"
},
{
"check":"content.success",
"expect":true,
"comparator":"eq",
"check_value":true,
"check_result":"pass"
}
]
}
],
"response_time":"11.42"
},
{
"name":"/api/users/1548560768589",
"status":"success",
"attachment":"",
"meta_datas":{
"name":"/api/users/1548560768589",
"data":[
{
"request":{
"url":"http://127.0.0.1:5000/api/users/1548560768589",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"Accept-Encoding":"gzip, deflate",
"Accept":"*/*",
"Connection":"keep-alive",
"device_sn":"mmHBimjzK4Pk6mg",
"token":"C3olNHYCMWfSQkCW",
"Content-Type":"application/json",
"Content-Length":"39"
},
"body":"{&#34;name&#34;: &#34;user1&#34;, &#34;password&#34;: &#34;123456&#34;}"
},
"response":{
"ok":true,
"url":"http://127.0.0.1:5000/api/users/1548560768589",
"status_code":201,
"reason":"CREATED",
"cookies":{},
"encoding":"None",
"headers":{
"Content-Type":"application/json",
"Content-Length":"54",
"Server":"Werkzeug/0.14.1 Python/3.6.5+",
"Date":"Sun, 27 Jan 2019 03:46:08 GMT"
},
"content_type":"application/json",
"json":{
"success":true,
"msg":"user created successfully."
}
}
}
],
"stat":{
"response_time_ms":2.8,
"elapsed_ms":1.748,
"content_size":54
},
"validators":[
{
"check":"status_code",
"expect":201,
"comparator":"eq",
"check_value":201,
"check_result":"pass"
},
{
"check":"headers.Content-Type",
"expect":"application/json",
"comparator":"eq",
"check_value":"application/json",
"check_result":"pass"
},
{
"check":"content.success",
"expect":true,
"comparator":"eq",
"check_value":true,
"check_result":"pass"
},
{
"check":"content.msg",
"expect":"user created successfully.",
"comparator":"eq",
"check_value":"user created successfully.",
"check_result":"pass"
}
]
},
"meta_datas_expanded":[
{
"name":"/api/users/1548560768589",
"data":[
{
"request":{
"url":"http://127.0.0.1:5000/api/users/1548560768589",
"method":"POST",
"headers":{
"User-Agent":"python-requests/2.18.4",
"Accept-Encoding":"gzip, deflate",
"Accept":"*/*",
"Connection":"keep-alive",
"device_sn":"mmHBimjzK4Pk6mg",
"token":"C3olNHYCMWfSQkCW",
"Content-Type":"application/json",
"Content-Length":"39"
},
"body":"{&#34;name&#34;: &#34;user1&#34;, &#34;password&#34;: &#34;123456&#34;}"
},
"response":{
"ok":true,
"url":"http://127.0.0.1:5000/api/users/1548560768589",
"status_code":201,
"reason":"CREATED",
"cookies":{},
"encoding":"None",
"headers":{
"Content-Type":"application/json",
"Content-Length":"54",
"Server":"Werkzeug/0.14.1 Python/3.6.5+",
"Date":"Sun, 27 Jan 2019 03:46:08 GMT"
},
"content_type":"application/json",
"json":{
"success":true,
"msg":"user created successfully."
}
}
}
],
"stat":{
"response_time_ms":2.8,
"elapsed_ms":1.748,
"content_size":54
},
"validators":[
{
"check":"status_code",
"expect":201,
"comparator":"eq",
"check_value":201,
"check_result":"pass"
},
{
"check":"headers.Content-Type",
"expect":"application/json",
"comparator":"eq",
"check_value":"application/json",
"check_result":"pass"
},
{
"check":"content.success",
"expect":true,
"comparator":"eq",
"check_value":true,
"check_result":"pass"
},
{
"check":"content.msg",
"expect":"user created successfully.",
"comparator":"eq",
"check_value":"user created successfully.",
"check_result":"pass"
}
]
}
],
"response_time":"2.80"
}
],
"name":"testcase description",
"in_out":{
"in":{},
"out":{}
}
}
]
}

View File

@ -0,0 +1,774 @@
<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">&times;</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>
{&#34;sign&#34;: &#34;bd37c4f16cacb2bede7d9c853cc86b1fe36bfce6&#34;}
</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">&times;</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>
{&#34;name&#34;: &#34;user1&#34;, &#34;password&#34;: &#34;123456&#34;}
</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>

View File

@ -0,0 +1,804 @@
<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:57:44</td>
</tr>
<tr>
<th>DURATION</th>
<td colspan="4">0.035 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 (0/1)</td>
<td colspan="2">2 (1/1/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: 1</td>
<td>FAILED: 1</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;">9.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: /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>: FwgRiO7CNA50DSU
</div>
<div>
<strong>os_platform</strong>: ios
</div>
<div>
<strong>Content-Length</strong>: 52
</div>
</td>
</tr>
<tr>
<th>body</th>
<td>
{&#34;sign&#34;: &#34;9c0c7e51c91ae963c833a4ccbab8d683c4a90c98&#34;}
</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:57:44 GMT
</div>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json
</td>
</tr>
<tr>
<th>json</th>
<td>
{'success': True, 'token': 'm7Lq6XCTELA14GB0'}
</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>9.01</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>2.396</td>
</tr>
</table>
</div>
</div>
</div>
</div>
</td>
</tr>
<tr id="record_1_2">
<th class="failure" style="width:5em;">failure</th>
<td colspan="2">/api/users/1000</td>
<td style="text-align:center;width:6em;">2.62 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: /api/users/1000</h3>
<h3>Request:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>url</th>
<td>
http://127.0.0.1:5000/api/users/1000
</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>: FwgRiO7CNA50DSU
</div>
<div>
<strong>token</strong>: baNLX1zhFYP11Seb
</div>
<div>
<strong>Content-Length</strong>: 39
</div>
</td>
</tr>
<tr>
<th>body</th>
<td>
{&#34;name&#34;: &#34;user1&#34;, &#34;password&#34;: &#34;123456&#34;}
</td>
</tr>
</table>
</div>
<h3>Response:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>ok</th>
<td>
False
</td>
</tr>
<tr>
<th>url</th>
<td>
http://127.0.0.1:5000/api/users/1000
</td>
</tr>
<tr>
<th>status_code</th>
<td>
403
</td>
</tr>
<tr>
<th>reason</th>
<td>
FORBIDDEN
</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>: 50
</div>
<div>
<strong>Server</strong>: Werkzeug/0.14.1 Python/3.6.5+
</div>
<div>
<strong>Date</strong>: Sun, 27 Jan 2019 03:57:44 GMT
</div>
</td>
</tr>
<tr>
<th>content_type</th>
<td>
application/json
</td>
</tr>
<tr>
<th>json</th>
<td>
{'success': False, 'msg': 'Authorization failed!'}
</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="failed">
status_code
</td>
<td>eq</td>
<td>201</td>
<td>403</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="failed">
content.success
</td>
<td>eq</td>
<td>True</td>
<td>False</td>
</tr>
<tr>
<td class="failed">
content.msg
</td>
<td>eq</td>
<td>user created successfully.</td>
<td>Authorization failed!</td>
</tr>
</table>
</div>
<h3>Statistics:</h3>
<div style="overflow: auto">
<table>
<tr>
<th>content_size(bytes)</th>
<td>50</td>
</tr>
<tr>
<th>response_time(ms)</th>
<td>2.62</td>
</tr>
<tr>
<th>elapsed(ms)</th>
<td>1.648</td>
</tr>
</table>
</div>
</div>
</div>
</div>
<a class="button" href="#popup_attachment_1_2">traceback</a>
<div id="popup_attachment_1_2" class="overlay">
<div class="popup">
<h2>Traceback Message</h2>
<a class="close" href="#record_1_2">&times;</a>
<div class="content"><pre>Traceback (most recent call last):
File &#34;/Users/debugtalk/.venv/httprunner/lib/python3.7/site-packages/HttpRunner-2.0.2-py3.7.egg/httprunner/api.py&#34;, line 54, in test
test_runner.run_test(test_dict)
httprunner.exceptions.ValidationFailure: validate: status_code equals 201(int) ==&gt; fail
403(int) equals 201(int)
validate: content.success equals True(bool) ==&gt; fail
False(bool) equals True(bool)
validate: content.msg equals user created successfully.(str) ==&gt; fail
Authorization failed!(str) equals user created successfully.(str)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File &#34;/Users/debugtalk/.venv/httprunner/lib/python3.7/site-packages/HttpRunner-2.0.2-py3.7.egg/httprunner/api.py&#34;, line 56, in test
self.fail(str(ex))
AssertionError: validate: status_code equals 201(int) ==&gt; fail
403(int) equals 201(int)
validate: content.success equals True(bool) ==&gt; fail
False(bool) equals True(bool)
validate: content.msg equals user created successfully.(str) ==&gt; fail
Authorization failed!(str) equals user created successfully.(str)
</pre></div>
</div>
</div>
</td>
</tr>
</table>
</body>

File diff suppressed because one or more lines are too long

66
data/testerhome-login.yml Normal file
View File

@ -0,0 +1,66 @@
- config:
name: testcase description
variables: {}
verify: False
- test:
name: /account/sign_in
request:
headers:
If-None-Match: W/"bc9ae267fdcbd89bf1dfaea10dea2b0e"
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_3) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36
method: GET
url: https://testerhome.com/account/sign_in
extract:
X_CSRF_Token: <meta name="csrf-token" content="(.*)" />
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, text/html; charset=utf-8]
- test:
name: /assets/big_logo-cd32144f74c18746f3dce33e1040e7dfe4c07c8e611e37f3868b1c16b5095da3.png
request:
headers:
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_3) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36
method: GET
url: https://testerhome.com/assets/big_logo-cd32144f74c18746f3dce33e1040e7dfe4c07c8e611e37f3868b1c16b5095da3.png
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, image/png]
- test:
name: /account/sign_in
request:
data:
commit: Sign In
user[login]: debugtalk
user[password]: XXXXXXXX
user[remember_me]: '1'
utf8:
headers:
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_3) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36
X-CSRF-Token: $X_CSRF_Token
X-Requested-With: XMLHttpRequest
method: POST
url: https://testerhome.com/account/sign_in
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, text/javascript; charset=utf-8]
- test:
name: /
request:
headers:
If-None-Match: W/"bad62c68dac27b01151516aad5c7f0be"
Turbolinks-Referrer: https://testerhome.com/account/sign_in
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_3) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36
method: GET
url: https://testerhome.com/
validate:
- eq: [status_code, 200]
- eq: [headers.Content-Type, text/html; charset=utf-8]

5
data/user_id.csv Normal file
View File

@ -0,0 +1,5 @@
user_id
1001
1002
1003
1004
1 user_id
2 1001
3 1002
4 1003
5 1004

View File

@ -0,0 +1,744 @@
<!doctype html>
<html lang="zh" class="no-js">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="HttpRunner V2.x User Documentation">
<meta name="author" content="debugtalk">
<meta name="lang:clipboard.copy" content="复制">
<meta name="lang:clipboard.copied" content="已复制">
<meta name="lang:search.language" content="jp">
<meta name="lang:search.pipeline.stopwords" content="True">
<meta name="lang:search.pipeline.trimmer" content="True">
<meta name="lang:search.result.none" content="没有找到符合条件的结果">
<meta name="lang:search.result.one" content="找到 1 个符合条件的结果">
<meta name="lang:search.result.other" content="# 个符合条件的结果">
<meta name="lang:search.tokenizer" content="[\uff0c\u3002]+">
<link rel="shortcut icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.0.4, mkdocs-material-4.4.3">
<title>Pipline - HttpRunner V2.x 中文使用文档</title>
<link rel="stylesheet" href="../../assets/stylesheets/application.30686662.css">
<link rel="stylesheet" href="../../assets/stylesheets/application-palette.a8b3c06d.css">
<meta name="theme-color" content="#3f51b5">
<script src="../../assets/javascripts/modernizr.74668098.js"></script>
<link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono&display=fallback">
<style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style>
<link rel="stylesheet" href="../../assets/fonts/material-icons.css">
<script>
window.ga = window.ga || function() {
(ga.q = ga.q || []).push(arguments)
}
ga.l = +new Date
/* Setup integration and send page view */
ga("create", "UA-114587036-2", "auto")
ga("set", "anonymizeIp", true)
ga("send", "pageview")
/* Register handler to log search on blur */
document.addEventListener("DOMContentLoaded", () => {
if (document.forms.search) {
var query = document.forms.search.query
query.addEventListener("blur", function() {
if (this.value) {
var path = document.location.pathname;
ga("send", "pageview", path + "?q=" + this.value)
}
})
}
})
</script>
<script async src="https://www.google-analytics.com/analytics.js"></script>
</head>
<body dir="ltr" data-md-color-primary="indigo" data-md-color-accent="indigo">
<svg class="md-svg">
<defs>
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg>
</defs>
</svg>
<input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
<input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
<label class="md-overlay" data-md-component="overlay" for="__drawer"></label>
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<div class="md-flex">
<div class="md-flex__cell md-flex__cell--shrink">
<a href="../.." title="HttpRunner V2.x 中文使用文档" class="md-header-nav__button md-logo">
<i class="md-icon"></i>
</a>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label>
</div>
<div class="md-flex__cell md-flex__cell--stretch">
<div class="md-flex__ellipsis md-header-nav__title" data-md-component="title">
<span class="md-header-nav__topic">
HttpRunner V2.x 中文使用文档
</span>
<span class="md-header-nav__topic">
Pipline
</span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="__search"></label>
<div class="md-search" data-md-component="search" role="dialog">
<label class="md-search__overlay" for="__search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" placeholder="搜索" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active">
<label class="md-icon md-search__icon" for="__search"></label>
<button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1">
&#xE5CD;
</button>
</form>
<div class="md-search__output">
<div class="md-search__scrollwrap" data-md-scrollfix>
<div class="md-search-result" data-md-component="result">
<div class="md-search-result__meta">
键入以开始搜索
</div>
<ol class="md-search-result__list"></ol>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div class="md-header-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
</div>
</div>
</nav>
</header>
<div class="md-container">
<main class="md-main" role="main">
<div class="md-main__inner md-grid" data-md-component="container">
<div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--primary" data-md-level="0">
<label class="md-nav__title md-nav__title--site" for="__drawer">
<a href="../.." title="HttpRunner V2.x 中文使用文档" class="md-nav__button md-logo">
<i class="md-icon"></i>
</a>
HttpRunner V2.x 中文使用文档
</label>
<div class="md-nav__source">
<a href="https://github.com/HttpRunner/HttpRunner" title="前往 Github 仓库" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#__github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
HttpRunner
</div>
</a>
</div>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../.." title="介绍" class="md-nav__link">
介绍
</a>
</li>
<li class="md-nav__item">
<a href="../../Installation/" title="安装说明" class="md-nav__link">
安装说明
</a>
</li>
<li class="md-nav__item">
<a href="../../quickstart/" title="快速上手" class="md-nav__link">
快速上手
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-4" type="checkbox" id="nav-4">
<label class="md-nav__link" for="nav-4">
基础概念
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-4">
基础概念
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../concept/nominal/" title="名词解释" class="md-nav__link">
名词解释
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-5" type="checkbox" id="nav-5">
<label class="md-nav__link" for="nav-5">
测试准备
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-5">
测试准备
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../prepare/record/" title="录制生成用例" class="md-nav__link">
录制生成用例
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/project-structure/" title="项目文件组织" class="md-nav__link">
项目文件组织
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/testcase-structure/" title="测试用例组织" class="md-nav__link">
测试用例组织
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/request-hook/" title="hook机制" class="md-nav__link">
hook机制
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/dot-env/" title="环境变量" class="md-nav__link">
环境变量
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/testcase-layer/" title="测试用例分层" class="md-nav__link">
测试用例分层
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/parameters/" title="参数化数据驱动" class="md-nav__link">
参数化数据驱动
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/validate-pretty/" title="Validate & Prettify" class="md-nav__link">
Validate & Prettify
</a>
</li>
<li class="md-nav__item">
<a href="../../prepare/security/" title="信息安全" class="md-nav__link">
信息安全
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-6" type="checkbox" id="nav-6">
<label class="md-nav__link" for="nav-6">
测试执行
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-6">
测试执行
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../run-tests/cli/" title="运行测试(CLI)" class="md-nav__link">
运行测试(CLI)
</a>
</li>
<li class="md-nav__item">
<a href="../../run-tests/report/" title="测试报告" class="md-nav__link">
测试报告
</a>
</li>
<li class="md-nav__item">
<a href="../../run-tests/load-test/" title="性能测试" class="md-nav__link">
性能测试
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item md-nav__item--active md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-7" type="checkbox" id="nav-7" checked>
<label class="md-nav__link" for="nav-7">
开发扩展
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-7">
开发扩展
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item md-nav__item--active">
<input class="md-toggle md-nav__toggle" data-md-toggle="toc" type="checkbox" id="__toc">
<a href="./" title="Pipline" class="md-nav__link md-nav__link--active">
Pipline
</a>
</li>
<li class="md-nav__item">
<a href="../dev-api/" title="基础库调用" class="md-nav__link">
基础库调用
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../../FAQ/" title="FAQ" class="md-nav__link">
FAQ
</a>
</li>
<li class="md-nav__item md-nav__item--nested">
<input class="md-toggle md-nav__toggle" data-md-toggle="nav-9" type="checkbox" id="nav-9">
<label class="md-nav__link" for="nav-9">
实践案例
</label>
<nav class="md-nav" data-md-component="collapsible" data-md-level="1">
<label class="md-nav__title" for="nav-9">
实践案例
</label>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="../../examples/testerhome-login/" title="TesterHome 登录" class="md-nav__link">
TesterHome 登录
</a>
</li>
</ul>
</nav>
</li>
<li class="md-nav__item">
<a href="../../related-docs/" title="相关资料" class="md-nav__link">
相关资料
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-content">
<article class="md-content__inner md-typeset">
<h1>Pipline</h1>
<p><img alt="" src="../../images/HttpRunner-architecture-diagram.svg" /></p>
</article>
</div>
</div>
</main>
<footer class="md-footer">
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid">
<a href="../../run-tests/load-test/" title="性能测试" class="md-flex md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-back md-footer-nav__button"></i>
</div>
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
上一页
</span>
性能测试
</span>
</div>
</a>
<a href="../dev-api/" title="基础库调用" class="md-flex md-footer-nav__link md-footer-nav__link--next" rel="next">
<div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title">
<span class="md-flex__ellipsis">
<span class="md-footer-nav__direction">
下一页
</span>
基础库调用
</span>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<i class="md-icon md-icon--arrow-forward md-footer-nav__button"></i>
</div>
</a>
</nav>
</div>
<div class="md-footer-meta md-typeset">
<div class="md-footer-meta__inner md-grid">
<div class="md-footer-copyright">
<div class="md-footer-copyright__highlight">
Copyright &copy; 2017 - 2019 debugtalk
</div>
powered by
<a href="https://www.mkdocs.org">MkDocs</a>
and
<a href="https://squidfunk.github.io/mkdocs-material/">
Material for MkDocs</a>
</div>
<div class="md-footer-social">
<link rel="stylesheet" href="../../assets/fonts/font-awesome.css">
<a href="https://debugtalk.com" class="md-footer-social__link fa fa-globe"></a>
<a href="https://github.com/httprunner" class="md-footer-social__link fa fa-github"></a>
</div>
</div>
</div>
</footer>
</div>
<script src="../../assets/javascripts/application.ac79c3b0.js"></script>
<script src="../../assets/javascripts/lunr/lunr.stemmer.support.js"></script>
<script>app.initialize({version:"1.0.4",url:{base:"../.."}})</script>
<script src="../../js/slardar.js"></script>
</body>
</html>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 514 KiB

BIN
images/charles-export.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 184 KiB

BIN
images/charles-save-har.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 202 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Some files were not shown because too many files have changed in this diff Show More