当前位置:网站首页>第十四天&postman
第十四天&postman
2022-08-05 00:53:00 【xbxbgk】
1.接口的批量运行&数据驱动
首先建立一个集合,在集合中创建需要运行的接口,点击run

勾选需要运行的接口

左侧为批量运行的设置,如迭代次数,迭代的间隔时间,选取的文件(将测试数据保存本地,一次性进行运行 在参数里面的数据文件值和取全局变量一致,使用{ {}},在断言里面取数据文件的值使用:data.字段名 )

选取所选文件的格式

在接口中用相应的{ {}}对应外部链接文本中数据,断言用data.引用


运行得到结果

2.接口的加密解密
加密方式base64
var username = CryptoJS.enc.Utf8.parse("admin")
var base64_username = CryptoJS.enc.Base64.stringify(username)
console.log(base64_username) //加密
var username = CryptoJS.enc.Base64.parse("YWRtaW4=")
var new_username = username.toString(CryptoJS.enc.Utf8)
console.log(new_username)//解密对文件进行加密

对文件进行解密

只加密不解密的加密方式:MD5,SHA1,SHA2,SHAN...
3.动态参数
{
{$timestamp}}:生成当前时间的时间戳
{
{$randomInt}}:生成0~1000的随机数
{
{$guid}}:生成随机的guid字符串4.MOCK接口

下一步输入接口名字

得到返回值界面

验证接口

引入与导出

边栏推荐
- 软件测试面试题:测试生命周期,测试过程分为几个阶段,以及各阶段的含义及使用的方法?
- Software testing interview questions: What are the three modules of LoadRunner?
- 主库预警日志报错ORA-00270
- MongoDB搭建及基础操作
- After the staged testing is complete, have you performed defect analysis?
- 2022多校第二场 K题 Link with Bracket Sequence I
- Binary tree [full solution] (C language)
- 2022牛客多校训练第二场 J题 Link with Arithmetic Progression
- LiveVideoStackCon 2022 上海站明日开幕!
- torch.autograd.grad finds the second derivative
猜你喜欢

DHCP的工作过程

4. PCIe 接口时序

Gartner Hype Cycle:超融合技术将在2年内到达“生产力成熟期”

Introduction to JVM class loading

【FreeRTOS】FreeRTOS与stm32内置堆栈的占用情况

Lattice PCIe Learning 1

详细全面的postman接口测试实战教程

Matlab uses plotting method for data simulation and simulation

活动推荐 | 快手StreamLake品牌发布会,8月10日一起见证!

gorm joint table query - actual combat
随机推荐
2022 Multi-school Second Session K Question Link with Bracket Sequence I
【翻译】CNCF对OpenTracing项目的存档
阶段性测试完成后,你进行缺陷分析了么?
GCC:屏蔽动态库之间的依赖
Matlab uses plotting method for data simulation and simulation
Introduction to JVM class loading
After the staged testing is complete, have you performed defect analysis?
2022杭电多校第三场 K题 Taxi
软件测试面试题:您以往所从事的软件测试工作中,是否使用了一些工具来进行软件缺陷(Bug)的管理?如果有,请结合该工具描述软件缺陷(Bug)跟踪管理的流程?
4. PCIe 接口时序
2022 The Third J Question Journey
GCC: paths to header and library files
The principle of NMS and its code realization
ORA-01105 ORA-03175
僵尸进程和孤儿进程
Memory Forensics Series 1
GCC:编译时库路径和运行时库路径
ora-01105 ora-03175
Software testing interview questions: Please draw the seven-layer network structure diagram of OSI and the four-layer structure diagram of TCP/IP?
Dynamic Programming/Knapsack Problem Summary/Summary - 01 Knapsack, Complete Knapsack