我在 JSON 模式下验证两个单独的 JSON 响应,它们是相同的,但只有一个区别是一个返回 'system' 作为 uri 格式的字符串,其他返回纯字符串,这导致我的第二个测试用例失败,因为对于第二个响应它还要查找 uri 格式的字符串。如何在我的架构中解决这个问题?
{
"id": "/coding",
"type": "array",
"items": {
"type": "object",
"properties": {
"system": {
"type": "string"
"format": "uri"
}
}
}
}