Closed chase001 closed 2 years ago
你好,未复现该问题,空列表可断言成功呢,您执行断言失败的报错是什么?响应内容的断言tab页截图看看,将响应josn体复制粘贴出来我们mock下试试。
请用以下返回数据格式:断言: "tsPavilionVOList": [
]
{ "code": "200", "msg": "success", "data": [ { "tradeshowId": 2808800066303, "tsName": "Consumer Electronics Show", "tsShortName": "HONGKONG-ELECTONICS-2022-OCT", "tsLocation": "AsiaWorld-Expo", "tsCountryCode": "HK", "tsCountryDesc": "", "tsStartDate": 1665417600000, "tsEndDate": 1665676800000, "tsGrpId": 2808800066303, "tsGrpCode": "EC", "tsLogoUrl": "", "tsImageUrl": "", "tsIds": "", "tsPavilionVOList": [
]
},
{
"tradeshowId": 2808800066329,
"tsName": "Mobile Electronics Show",
"tsShortName": "HONGKONG-MOBILE-ELECTONICS-2022-OCT",
"tsLocation": "AsiaWorld-Expo",
"tsCountryCode": "HK",
"tsCountryDesc": "",
"tsStartDate": 1666022400000,
"tsEndDate": 1666281600000,
"tsGrpId": 2808800066329,
"tsGrpCode": "ME",
"tsLogoUrl": "",
"tsImageUrl": "",
"tsIds": "",
"tsPavilionVOList": [
]
},
{
"tradeshowId": 2808800066337,
"tsName": "Smart Home & Appliances Show",
"tsShortName": "HONGKONG-SMART-HOME-APPLIANCES-2022-OCT",
"tsLocation": "AsiaWorld-Expo",
"tsCountryCode": "HK",
"tsCountryDesc": "",
"tsStartDate": 1666022400000,
"tsEndDate": 1666281600000,
"tsGrpId": 2808800066337,
"tsGrpCode": "SHA",
"tsLogoUrl": "",
"tsImageUrl": "",
"tsIds": "",
"tsPavilionVOList": [
]
},
{
"tradeshowId": 2808800066352,
"tsName": "Home & Kitchen Show",
"tsShortName": "HONGKONG-HOME-KITCHEN-2022-OCT",
"tsLocation": "AsiaWorld-Expo",
"tsCountryCode": "HK",
"tsCountryDesc": "",
"tsStartDate": 1666022400000,
"tsEndDate": 1666281600000,
"tsGrpId": 2808800066352,
"tsGrpCode": "HK",
"tsLogoUrl": "",
"tsImageUrl": "",
"tsIds": "",
"tsPavilionVOList": [
]
},
{
"tradeshowId": 2808800067384,
"tsName": "Fashion show",
"tsShortName": "HONGKONG-FASHION-2022-OCT",
"tsLocation": "ASIA-WORLD EXPO",
"tsCountryCode": "HK",
"tsCountryDesc": "",
"tsStartDate": 1666627200000,
"tsEndDate": 1666800000000,
"tsGrpId": 2808800067384,
"tsGrpCode": "FA",
"tsLogoUrl": "",
"tsImageUrl": "",
"tsIds": "",
"tsPavilionVOList": [
]
}
],
"timestamp": "2022-06-06 16:28:18"
}
您好,最新版本用您的数据进行断言也是可以成功的。
版本: v1.20.5-lts-9fe3acfd 是断言不为空,断言不等于,返回空,断言也成功
您好,感谢您的反馈,开始理解错了,已经反馈给研发,后续版本修复。
您好,经过和研发沟通: 1、数组不应该当成字符断言校验 2、如果非要当字符串判断,等于是完全匹配,不需要加 \ 来做转译
还是不成功,麻烦给确认法说
您好,其实数组不应该当成字符断言校验的,非要这么断言的话,后续版本我们优化下不等于[],断言失败。
v1.20.7-lts已修复。
联系方式
MeterSphere 交流群22 chase chase001@qq.com
MeterSphere 版本
v1.20.0-lts-c599aa69
使用外置数据库
是
问题描述
断言空列表为空不成功
重现步骤
期待的正确结果
No response
相关日志输出
No response
附加信息
No response