官方测试例子:https://learning.getpostman.com/docs/postman/scripts/test_examples
一些技巧记录:
1.快速设定变量-右键操作:
![](https://img.haomeiwen.com/i5072870/ea00a76d38d916b4.png)
好了之后可以右上角查看:
![](https://img.haomeiwen.com/i5072870/dad8be62a88844f0.png)
2.快速设定相应的编码格式,我们在请求接口应该都看到中文字符编码。通过右键快速操作编码
![](https://img.haomeiwen.com/i5072870/9a94dad39ddc9ef5.png)
如果在postmain的操作编码可以这样操作。
![](https://img.haomeiwen.com/i5072870/5709d2e3e713ae6d.png)
3.完成相应的登录之后token的预处理,同理可以借鉴到其他接口需要保留数据的内容
![](https://img.haomeiwen.com/i5072870/27927cdaf3decbc1.png)
具体可以参考:
https://jlhxxxx.github.io/postman-start.html
网友评论