Postman响应断言
生活随笔
收集整理的這篇文章主要介紹了
Postman响应断言
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
Tests響應斷言的幾種方式
(1)response body:contains string (校驗返回結果中是否包含某個字符串)
(2)response body:Is equal to string (校驗返回結果中是否等于該字符串)使用少,token會變
(3)response body:Json value check (校驗返回結果中某個字段是否等于某個值)
(4)response header:content-type header check (校驗響應頭是否包含某個值)
(5)response time is less than200ms (校驗響應時間是否少于200ms)
(6)Status code:code is 200 (校驗響應頭是否包含某個值)
1)response body:contains string
response header:content-type header check
response time is less than 200ms
Status code:code is 200
總結
以上是生活随笔為你收集整理的Postman响应断言的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Postman获取App端接口
- 下一篇: Postman工具之参数化