2392 lines
97 KiB
JSON
2392 lines
97 KiB
JSON
{
|
||
"start_time": "2025-06-20T11:12:26.598966",
|
||
"end_time": "2025-06-20T11:12:54.527663",
|
||
"duration_seconds": "27.93",
|
||
"overall_summary": {
|
||
"total_endpoints_defined": 6,
|
||
"endpoints_tested": 6,
|
||
"endpoints_passed": 0,
|
||
"endpoints_failed": 6,
|
||
"endpoints_error": 0,
|
||
"endpoints_skipped": 0,
|
||
"endpoints_partial_success": 0,
|
||
"endpoint_success_rate": "0.00%",
|
||
"total_test_cases_applicable": 114,
|
||
"total_test_cases_executed": 114,
|
||
"test_cases_passed": 81,
|
||
"test_cases_failed": 33,
|
||
"test_cases_error": 0,
|
||
"test_cases_skipped_in_endpoint": 0,
|
||
"test_case_success_rate": "71.05%",
|
||
"total_stages_defined": 1,
|
||
"total_stages_executed": 1,
|
||
"stages_passed": 0,
|
||
"stages_failed": 1,
|
||
"stages_error": 0,
|
||
"stages_skipped": 0,
|
||
"stage_success_rate": "0.00%"
|
||
},
|
||
"errors": [],
|
||
"endpoint_results": [
|
||
{
|
||
"endpoint_id": "POST /api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}",
|
||
"endpoint_name": "数据推送接口",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 4.245151,
|
||
"start_time": "2025-06-20T11:12:26.600559",
|
||
"end_time": "2025-06-20T11:12:30.845710",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-HEADER-001",
|
||
"test_case_name": "必需请求头Schema验证",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "缺少必需的请求头 X-Tenant-ID;缺少必需的请求头 X-Data-Domain",
|
||
"duration_seconds": 0.09456529101589695,
|
||
"timestamp": "2025-06-20T11:12:26.695427",
|
||
"validation_points": [
|
||
{
|
||
"header": "X-Tenant-ID",
|
||
"possible_names": [
|
||
"X-Tenant-ID"
|
||
],
|
||
"endpoint": "POST /api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}"
|
||
},
|
||
{
|
||
"header": "X-Data-Domain",
|
||
"possible_names": [
|
||
"X-Data-Domain"
|
||
],
|
||
"endpoint": "POST /api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.03178091696463525,
|
||
"timestamp": "2025-06-20T11:12:26.727300",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.024699834000784904,
|
||
"timestamp": "2025-06-20T11:12:26.752103",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "未在响应中找到需要检查的敏感字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-LLM-COMPLIANCE-001",
|
||
"test_case_name": "LLM合规性综合检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "[API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除] 通过: 当前API使用的是POST方法,其操作是数据推送(根据title字段“数据推送接口”),符合POST方法用于创建或提交数据的语义。",
|
||
"duration_seconds": 3.6070657910313457,
|
||
"timestamp": "2025-06-20T11:12:30.359358",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "当前API使用的是POST方法,其操作是数据推送(根据title字段“数据推送接口”),符合POST方法用于创建或提交数据的语义。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。;规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。",
|
||
"duration_seconds": 0.0426443750038743,
|
||
"timestamp": "2025-06-20T11:12:30.402121",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。"
|
||
},
|
||
{
|
||
"passed": true,
|
||
"message": "规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-PAGINATION-001",
|
||
"test_case_name": "分页参数检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:API不符合分页参数检查的准入规则(需包含'查询'/'列表'等关键词,且不包含'详情'等关键词)",
|
||
"duration_seconds": 0.0359227079898119,
|
||
"timestamp": "2025-06-20T11:12:30.438151",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}",
|
||
"method": "POST",
|
||
"summary": "数据推送接口",
|
||
"contains_include_keyword": false,
|
||
"contains_exclude_keyword": false
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-004",
|
||
"test_case_name": "资源集合复数命名检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}' 的最后一个路径分段 'push' 是动词,不需要使用复数形式。",
|
||
"duration_seconds": 0.03529691701987758,
|
||
"timestamp": "2025-06-20T11:12:30.473636",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}' 的最后一个路径分段 'push' 是动词,不需要使用复数形式。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-002",
|
||
"test_case_name": "资源路径名词检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}' 符合资源名词命名规范。",
|
||
"duration_seconds": 0.027868499979376793,
|
||
"timestamp": "2025-06-20T11:12:30.501659",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}' 符合资源名词命名规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-CORE-SCHEMA-001",
|
||
"test_case_name": "DMS核心存储服务API响应格式检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "字段'code'在schema中未标记为必填(required);字段'message'在schema中未标记为必填(required);字段'data'在schema中未标记为必填(required);响应schema符合标准格式: {'code':int or number or string, 'message':string, 'data': any}",
|
||
"duration_seconds": 0.02453091595089063,
|
||
"timestamp": "2025-06-20T11:12:30.526369",
|
||
"validation_points": [
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-CORE-FUNC-001",
|
||
"test_case_name": "Response Body JSON Schema Validation",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。",
|
||
"duration_seconds": 0.030045000021345913,
|
||
"timestamp": "2025-06-20T11:12:30.556778",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-003",
|
||
"test_case_name": "时间字段ISO 8601格式检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。",
|
||
"duration_seconds": 0.0322237090440467,
|
||
"timestamp": "2025-06-20T11:12:30.589185",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-URL-VERSION-001",
|
||
"test_case_name": "DMS API URL版本号检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API路径 '/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}' 正确以'/api/'开头;API路径 '/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}' 包含版本标识: 'v1'",
|
||
"duration_seconds": 0.025186375016346574,
|
||
"timestamp": "2025-06-20T11:12:30.614797",
|
||
"validation_points": [
|
||
{
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}"
|
||
},
|
||
{
|
||
"pattern_matched": "/v\\d+/",
|
||
"version_string": "v1",
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-001",
|
||
"test_case_name": "HTTPS Protocol Mandatory Verification",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "API通过HTTP (http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/message/push/example_schema/example_version) 响应了成功的状态码 200,这违反了HTTPS强制策略。",
|
||
"duration_seconds": 0.025891416997183114,
|
||
"timestamp": "2025-06-20T11:12:30.641141",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code -1 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。",
|
||
"duration_seconds": 0.030449500016402453,
|
||
"timestamp": "2025-06-20T11:12:30.671760",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code -1 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'isSearchCount' 类型不匹配时, 业务错误码应为 -1,但实际为 4006。",
|
||
"duration_seconds": 0.04390441701980308,
|
||
"timestamp": "2025-06-20T11:12:30.715957",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 4006,
|
||
"response_body": {
|
||
"code": 4006,
|
||
"message": "est officia in sit culpa",
|
||
"data": {
|
||
"total": 15,
|
||
"list": [
|
||
{
|
||
"dsid": "97",
|
||
"dataRegion": "ullamco est irure quis in",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null,
|
||
"key": 123
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4002",
|
||
"test_case_name": "Error Code -1 - Number Value Out of Range Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。",
|
||
"duration_seconds": 0.03910370799712837,
|
||
"timestamp": "2025-06-20T11:12:30.755358",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4006",
|
||
"test_case_name": "Error Code 4006 - Invalid Enum Value Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当 body 字段 'logic' 值为 'invalid_enum_mb23gg' (合法值为: ['AND', 'OR']) 时, 业务错误码应为 -1,但实际为 4006。",
|
||
"duration_seconds": 0.03301804204238579,
|
||
"timestamp": "2025-06-20T11:12:30.788680",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 4006,
|
||
"response_body": {
|
||
"code": 4006,
|
||
"message": "est officia in sit culpa",
|
||
"data": {
|
||
"total": 15,
|
||
"list": [
|
||
{
|
||
"dsid": "97",
|
||
"dataRegion": "ullamco est irure quis in",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null,
|
||
"key": 123
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code -1 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.02850899996701628,
|
||
"timestamp": "2025-06-20T11:12:30.817635",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code -1 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.027023624978028238,
|
||
"timestamp": "2025-06-20T11:12:30.845398",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}",
|
||
"endpoint_name": "地质单元列表查询",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 3.982699,
|
||
"start_time": "2025-06-20T11:12:30.845955",
|
||
"end_time": "2025-06-20T11:12:34.828654",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-HEADER-001",
|
||
"test_case_name": "必需请求头Schema验证",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "缺少必需的请求头 X-Tenant-ID;缺少必需的请求头 X-Data-Domain",
|
||
"duration_seconds": 0.028257082973141223,
|
||
"timestamp": "2025-06-20T11:12:30.875483",
|
||
"validation_points": [
|
||
{
|
||
"header": "X-Tenant-ID",
|
||
"possible_names": [
|
||
"X-Tenant-ID"
|
||
],
|
||
"endpoint": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}"
|
||
},
|
||
{
|
||
"header": "X-Data-Domain",
|
||
"possible_names": [
|
||
"X-Data-Domain"
|
||
],
|
||
"endpoint": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.02657733397791162,
|
||
"timestamp": "2025-06-20T11:12:30.902340",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.031323499977588654,
|
||
"timestamp": "2025-06-20T11:12:30.933823",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "未在响应中找到需要检查的敏感字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-LLM-COMPLIANCE-001",
|
||
"test_case_name": "LLM合规性综合检查",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "[API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除] 不通过: 当前API使用了POST方法,但根据其标题“地质单元列表查询”和描述信息,该操作更像是一个检索操作,应使用GET方法而非POST方法。",
|
||
"duration_seconds": 3.4000928750028834,
|
||
"timestamp": "2025-06-20T11:12:34.334318",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "当前API使用了POST方法,但根据其标题“地质单元列表查询”和描述信息,该操作更像是一个检索操作,应使用GET方法而非POST方法。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。;规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。",
|
||
"duration_seconds": 0.07624341698829085,
|
||
"timestamp": "2025-06-20T11:12:34.410940",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。"
|
||
},
|
||
{
|
||
"passed": true,
|
||
"message": "规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-PAGINATION-001",
|
||
"test_case_name": "分页参数检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API请求包含所有标准分页参数:pageNo、pageSize和isSearchCount",
|
||
"duration_seconds": 0.032602666004095227,
|
||
"timestamp": "2025-06-20T11:12:34.443694",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}",
|
||
"method": "POST"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-004",
|
||
"test_case_name": "资源集合复数命名检查",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}' 的最后一个路径分段 'cd_geo_unit' 可能不是复数形式,建议对资源集合使用复数命名。",
|
||
"duration_seconds": 0.02972475002752617,
|
||
"timestamp": "2025-06-20T11:12:34.473765",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}",
|
||
"segment": "cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-002",
|
||
"test_case_name": "资源路径名词检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}' 符合资源名词命名规范。",
|
||
"duration_seconds": 0.03693150001345202,
|
||
"timestamp": "2025-06-20T11:12:34.511065",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}' 符合资源名词命名规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-CORE-SCHEMA-001",
|
||
"test_case_name": "DMS核心存储服务API响应格式检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "字段'code'在schema中未标记为必填(required);字段'message'在schema中未标记为必填(required);字段'data'在schema中未标记为必填(required);响应schema符合标准格式: {'code':int or number or string, 'message':string, 'data': any}",
|
||
"duration_seconds": 0.02519658295204863,
|
||
"timestamp": "2025-06-20T11:12:34.536578",
|
||
"validation_points": [
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-CORE-FUNC-001",
|
||
"test_case_name": "Response Body JSON Schema Validation",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。",
|
||
"duration_seconds": 0.025696666969452053,
|
||
"timestamp": "2025-06-20T11:12:34.562655",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-003",
|
||
"test_case_name": "时间字段ISO 8601格式检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。",
|
||
"duration_seconds": 0.025099708989728242,
|
||
"timestamp": "2025-06-20T11:12:34.588057",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-URL-VERSION-001",
|
||
"test_case_name": "DMS API URL版本号检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}' 正确以'/api/'开头;API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}' 包含版本标识: 'v1'",
|
||
"duration_seconds": 0.031154332973528653,
|
||
"timestamp": "2025-06-20T11:12:34.619553",
|
||
"validation_points": [
|
||
{
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}"
|
||
},
|
||
{
|
||
"pattern_matched": "/v\\d+/",
|
||
"version_string": "v1",
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-001",
|
||
"test_case_name": "HTTPS Protocol Mandatory Verification",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "API通过HTTP (http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit/1.0.0) 响应了成功的状态码 200,这违反了HTTPS强制策略。",
|
||
"duration_seconds": 0.02681454096455127,
|
||
"timestamp": "2025-06-20T11:12:34.646809",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code -1 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当查询参数 'pageNo' (路径: 'pageNo') 类型不匹配时, 业务错误码应为 -1,但实际为 82。",
|
||
"duration_seconds": 0.031216458999551833,
|
||
"timestamp": "2025-06-20T11:12:34.678365",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 82,
|
||
"response_body": {
|
||
"code": 82,
|
||
"message": "labore eu",
|
||
"data": {
|
||
"total": 43,
|
||
"list": [
|
||
{
|
||
"dsid": "1",
|
||
"dataRegion": "velit",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code -1 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'isSearchCount' 类型不匹配时, 业务错误码应为 -1,但实际为 94。",
|
||
"duration_seconds": 0.026928125007543713,
|
||
"timestamp": "2025-06-20T11:12:34.705622",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 94,
|
||
"response_body": {
|
||
"code": 94,
|
||
"message": "laborum",
|
||
"data": {
|
||
"total": 34,
|
||
"list": [
|
||
{
|
||
"dsid": "83",
|
||
"dataRegion": "laboris",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4002",
|
||
"test_case_name": "Error Code -1 - Number Value Out of Range Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当 query 字段 'pageNo' 值为 0.0 (超出范围: min=1.0, max=None) 时, 业务错误码应为 -1,但实际为 32。",
|
||
"duration_seconds": 0.02961479203077033,
|
||
"timestamp": "2025-06-20T11:12:34.735590",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 32,
|
||
"response_body": {
|
||
"code": 32,
|
||
"message": "est",
|
||
"data": {
|
||
"total": 65,
|
||
"list": [
|
||
{
|
||
"dsid": "6",
|
||
"dataRegion": "sunt nulla",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "56",
|
||
"dataRegion": "est dolore",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "38",
|
||
"dataRegion": "Ut",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4006",
|
||
"test_case_name": "Error Code 4006 - Invalid Enum Value Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当 body 字段 'logic' 值为 'invalid_enum_kny9if' (合法值为: ['AND', 'OR']) 时, 业务错误码应为 -1,但实际为 25。",
|
||
"duration_seconds": 0.03531320800539106,
|
||
"timestamp": "2025-06-20T11:12:34.771056",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 25,
|
||
"response_body": {
|
||
"code": 25,
|
||
"message": "Ut tempor ut",
|
||
"data": {
|
||
"total": 60,
|
||
"list": [
|
||
{
|
||
"dsid": "64",
|
||
"dataRegion": "irure",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "50",
|
||
"dataRegion": "anim consequat incididunt nisi ut",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "33",
|
||
"dataRegion": "est mollit nisi",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code -1 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.028313999995589256,
|
||
"timestamp": "2025-06-20T11:12:34.799904",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code -1 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.028058000025339425,
|
||
"timestamp": "2025-06-20T11:12:34.828417",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "PUT /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据修改",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 4.622386,
|
||
"start_time": "2025-06-20T11:12:34.828842",
|
||
"end_time": "2025-06-20T11:12:39.451228",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-HEADER-001",
|
||
"test_case_name": "必需请求头Schema验证",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "缺少必需的请求头 X-Tenant-ID;缺少必需的请求头 X-Data-Domain",
|
||
"duration_seconds": 0.024927124963141978,
|
||
"timestamp": "2025-06-20T11:12:34.854795",
|
||
"validation_points": [
|
||
{
|
||
"header": "X-Tenant-ID",
|
||
"possible_names": [
|
||
"X-Tenant-ID"
|
||
],
|
||
"endpoint": "PUT /api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
},
|
||
{
|
||
"header": "X-Data-Domain",
|
||
"possible_names": [
|
||
"X-Data-Domain"
|
||
],
|
||
"endpoint": "PUT /api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.02565924997907132,
|
||
"timestamp": "2025-06-20T11:12:34.880699",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.027890582976397127,
|
||
"timestamp": "2025-06-20T11:12:34.908832",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "未在响应中找到需要检查的敏感字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-LLM-COMPLIANCE-001",
|
||
"test_case_name": "LLM合规性综合检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "[API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除] 通过: 当前API使用了PUT方法,且其标题为“地质单元数据修改”,符合PUT方法用于更新的语义",
|
||
"duration_seconds": 4.108188499987591,
|
||
"timestamp": "2025-06-20T11:12:39.017380",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "当前API使用了PUT方法,且其标题为“地质单元数据修改”,符合PUT方法用于更新的语义"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。",
|
||
"duration_seconds": 0.0440264159697108,
|
||
"timestamp": "2025-06-20T11:12:39.061714",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-PAGINATION-001",
|
||
"test_case_name": "分页参数检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:API不符合分页参数检查的准入规则(需包含'查询'/'列表'等关键词,且不包含'详情'等关键词)",
|
||
"duration_seconds": 0.026922125020064414,
|
||
"timestamp": "2025-06-20T11:12:39.088786",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"method": "PUT",
|
||
"summary": "地质单元数据修改",
|
||
"contains_include_keyword": false,
|
||
"contains_exclude_keyword": false
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-004",
|
||
"test_case_name": "资源集合复数命名检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:PUT 方法,不适用于资源集合复数检查。",
|
||
"duration_seconds": 0.026237249956466258,
|
||
"timestamp": "2025-06-20T11:12:39.115507",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过检查:PUT 方法,不适用于资源集合复数检查。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-002",
|
||
"test_case_name": "资源路径名词检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 符合资源名词命名规范。",
|
||
"duration_seconds": 0.023874083010014147,
|
||
"timestamp": "2025-06-20T11:12:39.139861",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 符合资源名词命名规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-CORE-SCHEMA-001",
|
||
"test_case_name": "DMS核心存储服务API响应格式检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "字段'code'在schema中未标记为必填(required);字段'message'在schema中未标记为必填(required);字段'data'在schema中未标记为必填(required);响应schema符合标准格式: {'code':int or number or string, 'message':string, 'data': any}",
|
||
"duration_seconds": 0.02853912499267608,
|
||
"timestamp": "2025-06-20T11:12:39.168868",
|
||
"validation_points": [
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-CORE-FUNC-001",
|
||
"test_case_name": "Response Body JSON Schema Validation",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "针对 PUT http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit (状态码 200) 的响应体 conforms to the JSON schema.",
|
||
"duration_seconds": 0.037734624987933785,
|
||
"timestamp": "2025-06-20T11:12:39.207144",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "针对 PUT http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit (状态码 200) 的响应体 conforms to the JSON schema."
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-003",
|
||
"test_case_name": "时间字段ISO 8601格式检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。",
|
||
"duration_seconds": 0.024971375009045005,
|
||
"timestamp": "2025-06-20T11:12:39.232463",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-URL-VERSION-001",
|
||
"test_case_name": "DMS API URL版本号检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 正确以'/api/'开头;API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 包含版本标识: 'v1'",
|
||
"duration_seconds": 0.02681829099310562,
|
||
"timestamp": "2025-06-20T11:12:39.259912",
|
||
"validation_points": [
|
||
{
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
},
|
||
{
|
||
"pattern_matched": "/v\\d+/",
|
||
"version_string": "v1",
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-001",
|
||
"test_case_name": "HTTPS Protocol Mandatory Verification",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "API通过HTTP (http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit) 响应了成功的状态码 200,这违反了HTTPS强制策略。",
|
||
"duration_seconds": 0.02383545902557671,
|
||
"timestamp": "2025-06-20T11:12:39.284173",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code -1 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当查询参数 'id' (路径: 'id') 类型不匹配时, 业务错误码应为 -1,但实际为 97。",
|
||
"duration_seconds": 0.025052250013686717,
|
||
"timestamp": "2025-06-20T11:12:39.309540",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 97,
|
||
"response_body": {
|
||
"code": 97,
|
||
"message": "consectetur enim amet exercitation deserunt",
|
||
"data": false
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code -1 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'id' 类型不匹配时, 业务错误码应为 -1,但实际为 54。",
|
||
"duration_seconds": 0.03644966700812802,
|
||
"timestamp": "2025-06-20T11:12:39.346315",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 54,
|
||
"response_body": {
|
||
"code": 54,
|
||
"message": "Ut reprehenderit in dolore voluptate",
|
||
"data": false
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4002",
|
||
"test_case_name": "Error Code -1 - Number Value Out of Range Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。",
|
||
"duration_seconds": 0.023927708039991558,
|
||
"timestamp": "2025-06-20T11:12:39.370461",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4006",
|
||
"test_case_name": "Error Code 4006 - Invalid Enum Value Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确枚举值限制的字段。",
|
||
"duration_seconds": 0.030632291978690773,
|
||
"timestamp": "2025-06-20T11:12:39.401220",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确枚举值限制的字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code -1 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填请求体字段 'id' 时, 业务错误码应为 -1,但实际为 4003。",
|
||
"duration_seconds": 0.024585582956206053,
|
||
"timestamp": "2025-06-20T11:12:39.426154",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 4003,
|
||
"response_body": {
|
||
"code": 4003
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code -1 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填查询参数 'id' 时, 业务错误码应为 -1,但实际为 75。",
|
||
"duration_seconds": 0.02435804094420746,
|
||
"timestamp": "2025-06-20T11:12:39.450828",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 75,
|
||
"response_body": {
|
||
"code": 75,
|
||
"message": "laborum",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "DELETE /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据删除",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 4.493971,
|
||
"start_time": "2025-06-20T11:12:39.451445",
|
||
"end_time": "2025-06-20T11:12:43.945416",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-HEADER-001",
|
||
"test_case_name": "必需请求头Schema验证",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "缺少必需的请求头 X-Tenant-ID;缺少必需的请求头 X-Data-Domain",
|
||
"duration_seconds": 0.024264458974357694,
|
||
"timestamp": "2025-06-20T11:12:39.476944",
|
||
"validation_points": [
|
||
{
|
||
"header": "X-Tenant-ID",
|
||
"possible_names": [
|
||
"X-Tenant-ID"
|
||
],
|
||
"endpoint": "DELETE /api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
},
|
||
{
|
||
"header": "X-Data-Domain",
|
||
"possible_names": [
|
||
"X-Data-Domain"
|
||
],
|
||
"endpoint": "DELETE /api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.026790832984261215,
|
||
"timestamp": "2025-06-20T11:12:39.503818",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.025846583012025803,
|
||
"timestamp": "2025-06-20T11:12:39.529920",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "未在响应中找到需要检查的敏感字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-LLM-COMPLIANCE-001",
|
||
"test_case_name": "LLM合规性综合检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "[API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除] 通过: 该API的method为DELETE,且其title和description表明此操作用于删除地质单元数据,符合DELETE方法的语义",
|
||
"duration_seconds": 3.9907823750399984,
|
||
"timestamp": "2025-06-20T11:12:43.521089",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "该API的method为DELETE,且其title和description表明此操作用于删除地质单元数据,符合DELETE方法的语义"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。",
|
||
"duration_seconds": 0.04599050001706928,
|
||
"timestamp": "2025-06-20T11:12:43.567293",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-PAGINATION-001",
|
||
"test_case_name": "分页参数检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:API不符合分页参数检查的准入规则(需包含'查询'/'列表'等关键词,且不包含'详情'等关键词)",
|
||
"duration_seconds": 0.025764582969713956,
|
||
"timestamp": "2025-06-20T11:12:43.593350",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"method": "DELETE",
|
||
"summary": "地质单元数据删除",
|
||
"contains_include_keyword": false,
|
||
"contains_exclude_keyword": false
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-004",
|
||
"test_case_name": "资源集合复数命名检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:DELETE 方法,不适用于资源集合复数检查。",
|
||
"duration_seconds": 0.030530791031196713,
|
||
"timestamp": "2025-06-20T11:12:43.624234",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过检查:DELETE 方法,不适用于资源集合复数检查。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-002",
|
||
"test_case_name": "资源路径名词检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 符合资源名词命名规范。",
|
||
"duration_seconds": 0.027323084010276943,
|
||
"timestamp": "2025-06-20T11:12:43.652030",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 符合资源名词命名规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-CORE-SCHEMA-001",
|
||
"test_case_name": "DMS核心存储服务API响应格式检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "字段'code'在schema中未标记为必填(required);字段'message'在schema中未标记为必填(required);字段'data'在schema中未标记为必填(required);响应schema符合标准格式: {'code':int or number or string, 'message':string, 'data': any}",
|
||
"duration_seconds": 0.024637209018692374,
|
||
"timestamp": "2025-06-20T11:12:43.677143",
|
||
"validation_points": [
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-CORE-FUNC-001",
|
||
"test_case_name": "Response Body JSON Schema Validation",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "针对 DELETE http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit (状态码 200) 的响应体 conforms to the JSON schema.",
|
||
"duration_seconds": 0.02524933300446719,
|
||
"timestamp": "2025-06-20T11:12:43.702993",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "针对 DELETE http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit (状态码 200) 的响应体 conforms to the JSON schema."
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-003",
|
||
"test_case_name": "时间字段ISO 8601格式检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。",
|
||
"duration_seconds": 0.026876416988670826,
|
||
"timestamp": "2025-06-20T11:12:43.730082",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-URL-VERSION-001",
|
||
"test_case_name": "DMS API URL版本号检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 正确以'/api/'开头;API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 包含版本标识: 'v1'",
|
||
"duration_seconds": 0.023698333010543138,
|
||
"timestamp": "2025-06-20T11:12:43.754162",
|
||
"validation_points": [
|
||
{
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
},
|
||
{
|
||
"pattern_matched": "/v\\d+/",
|
||
"version_string": "v1",
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-001",
|
||
"test_case_name": "HTTPS Protocol Mandatory Verification",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "API通过HTTP (http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit) 响应了成功的状态码 200,这违反了HTTPS强制策略。",
|
||
"duration_seconds": 0.02918433299055323,
|
||
"timestamp": "2025-06-20T11:12:43.783802",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code -1 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当查询参数 'id' (路径: 'id') 类型不匹配时, 业务错误码应为 -1,但实际为 18。",
|
||
"duration_seconds": 0.02521949994843453,
|
||
"timestamp": "2025-06-20T11:12:43.809502",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 18,
|
||
"response_body": {
|
||
"code": 18,
|
||
"message": "occaecat elit ut nostrud",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code -1 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'version' 类型不匹配时, 业务错误码应为 -1,但实际为 85。",
|
||
"duration_seconds": 0.026431583042722195,
|
||
"timestamp": "2025-06-20T11:12:43.836208",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 85,
|
||
"response_body": {
|
||
"code": 85,
|
||
"message": "qui anim",
|
||
"data": false
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4002",
|
||
"test_case_name": "Error Code -1 - Number Value Out of Range Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。",
|
||
"duration_seconds": 0.0328562919748947,
|
||
"timestamp": "2025-06-20T11:12:43.869363",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4006",
|
||
"test_case_name": "Error Code 4006 - Invalid Enum Value Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确枚举值限制的字段。",
|
||
"duration_seconds": 0.024620332987979054,
|
||
"timestamp": "2025-06-20T11:12:43.894419",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确枚举值限制的字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code -1 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.02552937500877306,
|
||
"timestamp": "2025-06-20T11:12:43.920407",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code -1 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填查询参数 'id' 时, 业务错误码应为 -1,但实际为 93。",
|
||
"duration_seconds": 0.024346542020794004,
|
||
"timestamp": "2025-06-20T11:12:43.945112",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 93,
|
||
"response_body": {
|
||
"code": 93,
|
||
"message": "Excepteur est",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据添加",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 6.110042,
|
||
"start_time": "2025-06-20T11:12:43.945645",
|
||
"end_time": "2025-06-20T11:12:50.055687",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-HEADER-001",
|
||
"test_case_name": "必需请求头Schema验证",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "缺少必需的请求头 X-Tenant-ID;缺少必需的请求头 X-Data-Domain",
|
||
"duration_seconds": 0.02426058304263279,
|
||
"timestamp": "2025-06-20T11:12:43.971260",
|
||
"validation_points": [
|
||
{
|
||
"header": "X-Tenant-ID",
|
||
"possible_names": [
|
||
"X-Tenant-ID"
|
||
],
|
||
"endpoint": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
},
|
||
{
|
||
"header": "X-Data-Domain",
|
||
"possible_names": [
|
||
"X-Data-Domain"
|
||
],
|
||
"endpoint": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.027869667042978108,
|
||
"timestamp": "2025-06-20T11:12:43.999341",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.03104854200500995,
|
||
"timestamp": "2025-06-20T11:12:44.030793",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "未在响应中找到需要检查的敏感字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-LLM-COMPLIANCE-001",
|
||
"test_case_name": "LLM合规性综合检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "[API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除] 通过: 当前API的HTTP方法为POST,且其标题为“地质单元数据添加”,描述符合创建资源的操作,因此符合该标准。",
|
||
"duration_seconds": 5.5097802500240505,
|
||
"timestamp": "2025-06-20T11:12:49.540993",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "当前API的HTTP方法为POST,且其标题为“地质单元数据添加”,描述符合创建资源的操作,因此符合该标准。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。;规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。",
|
||
"duration_seconds": 0.059930791961960495,
|
||
"timestamp": "2025-06-20T11:12:49.601222",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。"
|
||
},
|
||
{
|
||
"passed": true,
|
||
"message": "规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-PAGINATION-001",
|
||
"test_case_name": "分页参数检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:API不符合分页参数检查的准入规则(需包含'查询'/'列表'等关键词,且不包含'详情'等关键词)",
|
||
"duration_seconds": 0.041870166023727506,
|
||
"timestamp": "2025-06-20T11:12:49.643234",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"method": "POST",
|
||
"summary": "地质单元数据添加",
|
||
"contains_include_keyword": false,
|
||
"contains_exclude_keyword": false
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-004",
|
||
"test_case_name": "资源集合复数命名检查",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 的最后一个路径分段 'cd_geo_unit' 可能不是复数形式,建议对资源集合使用复数命名。",
|
||
"duration_seconds": 0.03810308297397569,
|
||
"timestamp": "2025-06-20T11:12:49.682118",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"segment": "cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-002",
|
||
"test_case_name": "资源路径名词检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 符合资源名词命名规范。",
|
||
"duration_seconds": 0.04503166698850691,
|
||
"timestamp": "2025-06-20T11:12:49.727613",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 符合资源名词命名规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-CORE-SCHEMA-001",
|
||
"test_case_name": "DMS核心存储服务API响应格式检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "字段'code'在schema中未标记为必填(required);字段'message'在schema中未标记为必填(required);字段'data'在schema中未标记为必填(required);响应schema符合标准格式: {'code':int or number or string, 'message':string, 'data': any}",
|
||
"duration_seconds": 0.03624983405461535,
|
||
"timestamp": "2025-06-20T11:12:49.764333",
|
||
"validation_points": [
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "201"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-CORE-FUNC-001",
|
||
"test_case_name": "Response Body JSON Schema Validation",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。",
|
||
"duration_seconds": 0.035078874963801354,
|
||
"timestamp": "2025-06-20T11:12:49.799935",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-003",
|
||
"test_case_name": "时间字段ISO 8601格式检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。",
|
||
"duration_seconds": 0.024587916035670787,
|
||
"timestamp": "2025-06-20T11:12:49.824714",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-URL-VERSION-001",
|
||
"test_case_name": "DMS API URL版本号检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 正确以'/api/'开头;API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit' 包含版本标识: 'v1'",
|
||
"duration_seconds": 0.024693458050023764,
|
||
"timestamp": "2025-06-20T11:12:49.849724",
|
||
"validation_points": [
|
||
{
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
},
|
||
{
|
||
"pattern_matched": "/v\\d+/",
|
||
"version_string": "v1",
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-001",
|
||
"test_case_name": "HTTPS Protocol Mandatory Verification",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "API通过HTTP (http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit) 响应了成功的状态码 200,这违反了HTTPS强制策略。",
|
||
"duration_seconds": 0.03252179204719141,
|
||
"timestamp": "2025-06-20T11:12:49.882595",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code -1 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。",
|
||
"duration_seconds": 0.025350167008582503,
|
||
"timestamp": "2025-06-20T11:12:49.908706",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code -1 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'version' 类型不匹配时, 业务错误码应为 -1,但实际为 46。",
|
||
"duration_seconds": 0.02687666699057445,
|
||
"timestamp": "2025-06-20T11:12:49.935866",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 46,
|
||
"response_body": {
|
||
"code": 46,
|
||
"message": "ex",
|
||
"data": false
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4002",
|
||
"test_case_name": "Error Code -1 - Number Value Out of Range Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。",
|
||
"duration_seconds": 0.02771466603735462,
|
||
"timestamp": "2025-06-20T11:12:49.963873",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4006",
|
||
"test_case_name": "Error Code 4006 - Invalid Enum Value Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确枚举值限制的字段。",
|
||
"duration_seconds": 0.029278542031534016,
|
||
"timestamp": "2025-06-20T11:12:49.993302",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确枚举值限制的字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code -1 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填请求体字段 'data.0.bsflag' 时, 业务错误码应为 -1,但实际为 31。",
|
||
"duration_seconds": 0.029600000008940697,
|
||
"timestamp": "2025-06-20T11:12:50.023452",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 31,
|
||
"response_body": {
|
||
"code": 31,
|
||
"message": "ea tempor",
|
||
"data": false
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code -1 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.03166429203702137,
|
||
"timestamp": "2025-06-20T11:12:50.055443",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "GET /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}",
|
||
"endpoint_name": "地质单元查询详情",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 4.383212,
|
||
"start_time": "2025-06-20T11:12:50.055843",
|
||
"end_time": "2025-06-20T11:12:54.439055",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-HEADER-001",
|
||
"test_case_name": "必需请求头Schema验证",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "缺少必需的请求头 X-Tenant-ID;缺少必需的请求头 X-Data-Domain",
|
||
"duration_seconds": 0.028821125044487417,
|
||
"timestamp": "2025-06-20T11:12:50.085415",
|
||
"validation_points": [
|
||
{
|
||
"header": "X-Tenant-ID",
|
||
"possible_names": [
|
||
"X-Tenant-ID"
|
||
],
|
||
"endpoint": "GET /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}"
|
||
},
|
||
{
|
||
"header": "X-Data-Domain",
|
||
"possible_names": [
|
||
"X-Data-Domain"
|
||
],
|
||
"endpoint": "GET /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.026660375006031245,
|
||
"timestamp": "2025-06-20T11:12:50.112363",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.0255947089754045,
|
||
"timestamp": "2025-06-20T11:12:50.138279",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "未在响应中找到需要检查的敏感字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-LLM-COMPLIANCE-001",
|
||
"test_case_name": "LLM合规性综合检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "[API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除] 通过: 当前API使用了GET方法,并且其操作是用于检索地质单元详情,符合标准要求。",
|
||
"duration_seconds": 3.7415315830148757,
|
||
"timestamp": "2025-06-20T11:12:53.880090",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "当前API使用了GET方法,并且其操作是用于检索地质单元详情,符合标准要求。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。",
|
||
"duration_seconds": 0.05670016602380201,
|
||
"timestamp": "2025-06-20T11:12:53.937182",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-PAGINATION-001",
|
||
"test_case_name": "分页参数检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过检查:API不符合分页参数检查的准入规则(需包含'查询'/'列表'等关键词,且不包含'详情'等关键词)",
|
||
"duration_seconds": 0.033698416023980826,
|
||
"timestamp": "2025-06-20T11:12:53.971188",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}",
|
||
"method": "GET",
|
||
"summary": "地质单元查询详情",
|
||
"contains_include_keyword": true,
|
||
"contains_exclude_keyword": true
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-004",
|
||
"test_case_name": "资源集合复数命名检查",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}' 的最后一个路径分段 'cd_geo_unit' 可能不是复数形式,建议对资源集合使用复数命名。",
|
||
"duration_seconds": 0.0273964160005562,
|
||
"timestamp": "2025-06-20T11:12:53.999144",
|
||
"validation_points": [
|
||
{
|
||
"path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}",
|
||
"segment": "cd_geo_unit"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-002",
|
||
"test_case_name": "资源路径名词检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}' 符合资源名词命名规范。",
|
||
"duration_seconds": 0.02955504198325798,
|
||
"timestamp": "2025-06-20T11:12:54.029551",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}' 符合资源名词命名规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-CORE-SCHEMA-001",
|
||
"test_case_name": "DMS核心存储服务API响应格式检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "字段'code'在schema中未标记为必填(required);字段'message'在schema中未标记为必填(required);字段'data'在schema中未标记为必填(required);响应schema符合标准格式: {'code':int or number or string, 'message':string, 'data': any}",
|
||
"duration_seconds": 0.027021082991268486,
|
||
"timestamp": "2025-06-20T11:12:54.057164",
|
||
"validation_points": [
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200",
|
||
"required_fields": []
|
||
},
|
||
{
|
||
"status_code": "200"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-CORE-FUNC-001",
|
||
"test_case_name": "Response Body JSON Schema Validation",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "针对 GET http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit/1.0.0/example_id (状态码 200) 的响应体 conforms to the JSON schema.",
|
||
"duration_seconds": 0.03106195799773559,
|
||
"timestamp": "2025-06-20T11:12:54.088590",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "针对 GET http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit/1.0.0/example_id (状态码 200) 的响应体 conforms to the JSON schema."
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-003",
|
||
"test_case_name": "时间字段ISO 8601格式检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。",
|
||
"duration_seconds": 0.030167624994646758,
|
||
"timestamp": "2025-06-20T11:12:54.119142",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "在API规范中未找到可供静态检查的时间相关字段(如 format: date-time 或 常见时间字段名)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-DMS-URL-VERSION-001",
|
||
"test_case_name": "DMS API URL版本号检查",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}' 正确以'/api/'开头;API路径 '/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}' 包含版本标识: 'v1'",
|
||
"duration_seconds": 0.03281570802209899,
|
||
"timestamp": "2025-06-20T11:12:54.152473",
|
||
"validation_points": [
|
||
{
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}"
|
||
},
|
||
{
|
||
"pattern_matched": "/v\\d+/",
|
||
"version_string": "v1",
|
||
"full_path": "/api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}/{id}"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-001",
|
||
"test_case_name": "HTTPS Protocol Mandatory Verification",
|
||
"test_case_severity": "严重",
|
||
"status": "失败",
|
||
"message": "API通过HTTP (http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/example_dms_instance_code/v1/cd_geo_unit/1.0.0/example_id) 响应了成功的状态码 200,这违反了HTTPS强制策略。",
|
||
"duration_seconds": 0.028424166957847774,
|
||
"timestamp": "2025-06-20T11:12:54.181190",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code -1 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。",
|
||
"duration_seconds": 0.028711332997772843,
|
||
"timestamp": "2025-06-20T11:12:54.210197",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code -1 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'isSearchCount' 类型不匹配时, 业务错误码应为 -1,但实际为 16。",
|
||
"duration_seconds": 0.037422124994918704,
|
||
"timestamp": "2025-06-20T11:12:54.247759",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 16,
|
||
"response_body": {
|
||
"code": 16,
|
||
"message": "commodo consectetur proident velit",
|
||
"data": {
|
||
"total": 31,
|
||
"list": [
|
||
{
|
||
"dsid": "26",
|
||
"dataRegion": "ea cillum",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "99",
|
||
"dataRegion": "pariatur dolor",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "38",
|
||
"dataRegion": "ut eiusmod",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4002",
|
||
"test_case_name": "Error Code -1 - Number Value Out of Range Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。",
|
||
"duration_seconds": 0.05045616696588695,
|
||
"timestamp": "2025-06-20T11:12:54.298374",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:未找到具有明确范围限制的数值字段。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4006",
|
||
"test_case_name": "Error Code 4006 - Invalid Enum Value Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当 body 字段 'logic' 值为 'invalid_enum_y9y8kz' (合法值为: ['AND', 'OR']) 时, 业务错误码应为 -1,但实际为 58。",
|
||
"duration_seconds": 0.04505399998743087,
|
||
"timestamp": "2025-06-20T11:12:54.343753",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 58,
|
||
"response_body": {
|
||
"code": 58,
|
||
"message": "occaecat",
|
||
"data": {
|
||
"total": 68,
|
||
"list": [
|
||
{
|
||
"dsid": "99",
|
||
"dataRegion": "ad",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "36",
|
||
"dataRegion": "proident magna irure",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "29",
|
||
"dataRegion": "voluptate ipsum esse officia",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code -1 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.04267499997513369,
|
||
"timestamp": "2025-06-20T11:12:54.386884",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code -1 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.0517881250125356,
|
||
"timestamp": "2025-06-20T11:12:54.438831",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
}
|
||
],
|
||
"stage_results": [
|
||
{
|
||
"stage_id": "generic_crud_validation_stage",
|
||
"stage_name": "Generic CRUD Validation Stage",
|
||
"description": "Performs a generic CRUD (Create, List, Read, Update, Delete) flow. It tries to dynamically discover API operations based on common keywords and HTTP methods. Field names for IDs, names, features, and JSON paths for list/detail objects are configurable via class attributes or can be set in `before_stage` based on `api_group_name`.",
|
||
"api_group_name": "地质单元",
|
||
"tags": [
|
||
"crud",
|
||
"generic_validation"
|
||
],
|
||
"overall_status": "失败",
|
||
"duration_seconds": "0.08",
|
||
"start_time": "2025-06-20T11:12:54",
|
||
"end_time": "2025-06-20T11:12:54",
|
||
"message": "测试阶段因步骤 'List and Find Created Resource' 的状态 (失败) 而中止.",
|
||
"executed_steps_count": 2,
|
||
"executed_steps": [
|
||
{
|
||
"step_name": "Create New Resource",
|
||
"description": null,
|
||
"lookup_key": "地质单元数据添加",
|
||
"resolved_endpoint": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"status": "通过",
|
||
"message": "",
|
||
"duration_seconds": "0.0000",
|
||
"timestamp": "2025-06-20T11:12:54+0800",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "状态码匹配 (200)."
|
||
}
|
||
],
|
||
"api_call_curl": "N/A",
|
||
"request_details": {
|
||
"method": "POST",
|
||
"url": "http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/your_dms_instance_code/v1/cd_geo_unit",
|
||
"headers": {
|
||
"tenant-id": "your-tenant-id",
|
||
"Content-Type": "application/json",
|
||
"Accept": "application/json",
|
||
"Authorization": "Bearer your-test-token"
|
||
},
|
||
"params": {},
|
||
"json_data": {
|
||
"version": "1.0.0",
|
||
"data": [
|
||
{
|
||
"wellCommonName": "TestResource_1750389174_6d202b",
|
||
"dataRegion": "Feature_1750389174"
|
||
}
|
||
]
|
||
},
|
||
"body": {
|
||
"version": "1.0.0",
|
||
"data": [
|
||
{
|
||
"wellCommonName": "TestResource_1750389174_6d202b",
|
||
"dataRegion": "Feature_1750389174"
|
||
}
|
||
]
|
||
},
|
||
"data": null,
|
||
"timeout": 30
|
||
},
|
||
"extracted_outputs": {},
|
||
"context_after_step_summary": {
|
||
"unique_resource_name": "TestResource_1750389174_6d202b",
|
||
"updated_resource_name": "TestResource_1750389174_6d202b_UPDATED",
|
||
"unique_feature_value": "Feature_1750389174",
|
||
"updated_feature_value": "Feature_1750389174_UPDATED",
|
||
"cfg_list_path_in_listresponse": "data.list",
|
||
"cfg_name_field_in_listitem": "wellCommonName",
|
||
"cfg_id_field_in_listitem": "dsid",
|
||
"cfg_resource_object_path_in_detailresponse": "data.list.0",
|
||
"cfg_name_field_in_detailresponse": "wellCommonName",
|
||
"cfg_id_field_in_detailresponse": "dsid",
|
||
"cfg_resource_object_path_in_updateresponse": "data.list.0",
|
||
"cfg_feature_field_name_for_validation": "dataRegion",
|
||
"dms_instance_code": "your_dms_instance_code",
|
||
"api_version": "1.0.0"
|
||
}
|
||
},
|
||
{
|
||
"step_name": "List and Find Created Resource",
|
||
"description": null,
|
||
"lookup_key": "地质单元列表查询",
|
||
"resolved_endpoint": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit/{version}",
|
||
"status": "失败",
|
||
"message": "Resource not found: Name 'TestResource_1750389174_6d202b' (field: wellCommonName) not found in list at path 'data.list'.",
|
||
"duration_seconds": "0.0000",
|
||
"timestamp": "2025-06-20T11:12:54+0800",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "状态码匹配 (200)."
|
||
},
|
||
{
|
||
"passed": false,
|
||
"message": "Resource not found: Name 'TestResource_1750389174_6d202b' (field: wellCommonName) not found in list at path 'data.list'."
|
||
}
|
||
],
|
||
"api_call_curl": "N/A",
|
||
"request_details": {
|
||
"method": "POST",
|
||
"url": "http://127.0.0.1:4523/m1/6389742-6086420-default/api/dms/your_dms_instance_code/v1/cd_geo_unit/1.0.0",
|
||
"headers": {
|
||
"tenant-id": "your-tenant-id",
|
||
"Content-Type": "application/json",
|
||
"Accept": "application/json",
|
||
"Authorization": "Bearer your-test-token"
|
||
},
|
||
"params": {
|
||
"pageNo": 1,
|
||
"pageSize": 10
|
||
},
|
||
"json_data": {
|
||
"isSearchCount": true,
|
||
"query": {
|
||
"fields": [
|
||
"dsid",
|
||
"wellCommonName",
|
||
"dataRegion"
|
||
],
|
||
"filter": {
|
||
"key": "wellCommonName",
|
||
"symbol": "=",
|
||
"realValue": [
|
||
"TestResource_1750389174_6d202b"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"body": {
|
||
"isSearchCount": true,
|
||
"query": {
|
||
"fields": [
|
||
"dsid",
|
||
"wellCommonName",
|
||
"dataRegion"
|
||
],
|
||
"filter": {
|
||
"key": "wellCommonName",
|
||
"symbol": "=",
|
||
"realValue": [
|
||
"TestResource_1750389174_6d202b"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"data": null,
|
||
"timeout": 30
|
||
},
|
||
"extracted_outputs": {},
|
||
"context_after_step_summary": {
|
||
"unique_resource_name": "TestResource_1750389174_6d202b",
|
||
"updated_resource_name": "TestResource_1750389174_6d202b_UPDATED",
|
||
"unique_feature_value": "Feature_1750389174",
|
||
"updated_feature_value": "Feature_1750389174_UPDATED",
|
||
"cfg_list_path_in_listresponse": "data.list",
|
||
"cfg_name_field_in_listitem": "wellCommonName",
|
||
"cfg_id_field_in_listitem": "dsid",
|
||
"cfg_resource_object_path_in_detailresponse": "data.list.0",
|
||
"cfg_name_field_in_detailresponse": "wellCommonName",
|
||
"cfg_id_field_in_detailresponse": "dsid",
|
||
"cfg_resource_object_path_in_updateresponse": "data.list.0",
|
||
"cfg_feature_field_name_for_validation": "dataRegion",
|
||
"dms_instance_code": "your_dms_instance_code",
|
||
"api_version": "1.0.0"
|
||
}
|
||
}
|
||
],
|
||
"final_stage_context_summary": {
|
||
"unique_resource_name": "TestResource_1750389174_6d202b",
|
||
"updated_resource_name": "TestResource_1750389174_6d202b_UPDATED",
|
||
"unique_feature_value": "Feature_1750389174",
|
||
"updated_feature_value": "Feature_1750389174_UPDATED",
|
||
"cfg_list_path_in_listresponse": "data.list",
|
||
"cfg_name_field_in_listitem": "wellCommonName",
|
||
"cfg_id_field_in_listitem": "dsid",
|
||
"cfg_resource_object_path_in_detailresponse": "data.list.0",
|
||
"cfg_name_field_in_detailresponse": "wellCommonName",
|
||
"cfg_id_field_in_detailresponse": "dsid",
|
||
"cfg_resource_object_path_in_updateresponse": "data.list.0",
|
||
"cfg_feature_field_name_for_validation": "dataRegion",
|
||
"dms_instance_code": "your_dms_instance_code",
|
||
"api_version": "1.0.0"
|
||
}
|
||
}
|
||
],
|
||
"api_call_details_summary": []
|
||
} |