Comments (8)
@yileye 能先将格式调整为markdown么?这样实在是没法看清你的用例。
from httprunner.
@debugtalk 格式已经调整
from httprunner.
@yileye 我看了下你写的用例,总的来说没有啥问题,可能在第一个接口中,headers中的Content-Type
与实际不一致;因为如果你传的是json
而非data
,那么Content-Type
应该只能是application/json
。
另外,推荐在调试用例的时候打开抓包工具,方便看到你执行脚本时实际的请求和响应,然后再跟抓包得到的请求进行对比,基本上就能发现差异了。
from httprunner.
@debugtalk 嗯,可能是我还没有了解清楚脚本的结构,不太熟悉,我想实现的一个功能就是想再后续的请求中重用第一步登录的token,这个在脚本中应该如何使用?因为我后面的脚本在请求时都会验证是否在登录状态,所以会需要登录接口的Session
from httprunner.
@yileye 这块儿的说明已经挺多了。
你可以看下 issue #3 ;同时,QuickStart 里面的例子也完全满足你的要求。
from httprunner.
@debugtalk 好的,我先看看文档吧,我刚才找到了关于我刚才提到的问题的代码实现方式,和我之前实现的一样,应该是可以满足我的要求的
from httprunner.
@debugtalk 看了你的代码后收获很多,构思相当巧妙,之后如果有机会希望能为这个框架贡献一些代码,使框架更为健壮
from httprunner.
@yileye 十分欢迎!
from httprunner.
Related Issues (20)
- validate 失败后report无法正常生成 HOT 9
- 最新版本 v4.3.6为什么没有上传到pypi呢? HOT 1
- Error: init plugin failed: connect grpc plugin failed: Unrecognized remote plugin message HOT 2
- validate自定义函数校验失败时,report内容缺失
- log日志巨大,有什么解决思路吗? HOT 1
- 执行带 setupHooks 和 teardownHooks 的json用例时报错了,提示:[ERROR] fungo: exec command failed: error="exit status 9009" stderr=""
- 执行测试用例结束出现invalid memory address or nil pointer dereference [recovered]
- macOS安装完4.3.6后脚手架创建项目报错/Users/minxiao/.hrp/venv/bin/python3: No module named pip
- yml 文件里 的url结尾没有 “/”,但是在 看发起的请求和log 中 url 的结尾有 “/”,导致接口 404。 HOT 2
- When the assertion fails, an error message is generated, and a test report is not generated HOT 1
- 参数化驱动用例,用例名引用变量失败 HOT 1
- 执行hrp用例的时候,偶发的报python编译错误
- 使用低于v.4.3.3版本的hrp没办法生成报告
- 感觉hrp4基于go语言的版本不好集成到测试平台
- 使用4.3.6 转化har文件失败 HOT 2
- 运行的任务比较多时会发生错误
- 接口关联后${variable}引用为空
- hrp run *.yaml 默认把headers的参数的首字母大写
- hrun运行的时候希望能够支持不同的环境env, 实现多个环境便捷切换。
- 期望实现对数据库的测试校验,通过查询数据库的值和接口返回结果做比对验证。
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from httprunner.