postman报错:There was an error in evaluating the test script: JSONError: Unexpected token 'n' at 1:15
程序员文章站
2022-03-05 18:22:25
...
1.There was an error in evaluating the test script: JSONError: Unexpected token ‘n’ at 1:15 20200509150938nZ5W ^
原因:格式错误
//获取返回数据,JSON格式
var keytime= JSON.parse(responseBody);
错误原因:此处不需要转为JSON格式的
//设置成环境变量
pm.environment.set("key",keytime);