2385 lines
97 KiB
JSON
2385 lines
97 KiB
JSON
{
|
||
"start_time": "2025-06-26T01:42:53.788378",
|
||
"end_time": "2025-06-26T01:43:17.541541",
|
||
"duration_seconds": "23.75",
|
||
"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": 79,
|
||
"test_cases_failed": 35,
|
||
"test_cases_error": 0,
|
||
"test_cases_skipped_in_endpoint": 0,
|
||
"test_case_success_rate": "69.30%",
|
||
"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.12363,
|
||
"start_time": "2025-06-26T01:42:53.789166",
|
||
"end_time": "2025-06-26T01:42:57.912796",
|
||
"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.06788683298509568,
|
||
"timestamp": "2025-06-26T01:42:53.857206",
|
||
"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.027871124912053347,
|
||
"timestamp": "2025-06-26T01:42:53.885139",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.024820332997478545,
|
||
"timestamp": "2025-06-26T01:42:53.910041",
|
||
"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用于删除] 不通过: 该接口使用POST方法,但其功能描述为'数据推送接口',未明确说明是创建资源。根据RESTful设计原则,POST通常用于创建资源,若此接口并非用于创建资源,则不符合该合规性标准。",
|
||
"duration_seconds": 3.399107916979119,
|
||
"timestamp": "2025-06-26T01:42:57.309140",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "该接口使用POST方法,但其功能描述为'数据推送接口',未明确说明是创建资源。根据RESTful设计原则,POST通常用于创建资源,若此接口并非用于创建资源,则不符合该合规性标准。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。;规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。",
|
||
"duration_seconds": 0.05138299998361617,
|
||
"timestamp": "2025-06-26T01:42:57.360638",
|
||
"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.01933804200962186,
|
||
"timestamp": "2025-06-26T01:42:57.380126",
|
||
"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.02537695795763284,
|
||
"timestamp": "2025-06-26T01:42:57.406056",
|
||
"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.021336167003028095,
|
||
"timestamp": "2025-06-26T01:42:57.427657",
|
||
"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.019885707995854318,
|
||
"timestamp": "2025-06-26T01:42:57.447867",
|
||
"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.022114583989605308,
|
||
"timestamp": "2025-06-26T01:42:57.470284",
|
||
"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.023027457995340228,
|
||
"timestamp": "2025-06-26T01:42:57.493607",
|
||
"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.020154666039161384,
|
||
"timestamp": "2025-06-26T01:42:57.514254",
|
||
"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.021024083020165563,
|
||
"timestamp": "2025-06-26T01:42:57.535636",
|
||
"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.022656874964013696,
|
||
"timestamp": "2025-06-26T01:42:57.558587",
|
||
"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.02114487497601658,
|
||
"timestamp": "2025-06-26T01:42:57.580027",
|
||
"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.023892292054370046,
|
||
"timestamp": "2025-06-26T01:42:57.604299",
|
||
"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_4dp4w1' (合法值为: ['AND', 'OR']) 时, 业务错误码应为 -1,但实际为 4006。",
|
||
"duration_seconds": 0.027015124913305044,
|
||
"timestamp": "2025-06-26T01:42:57.631475",
|
||
"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.19807016698177904,
|
||
"timestamp": "2025-06-26T01:42:57.829781",
|
||
"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.08286491699982435,
|
||
"timestamp": "2025-06-26T01:42:57.912739",
|
||
"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.436445,
|
||
"start_time": "2025-06-26T01:42:57.912841",
|
||
"end_time": "2025-06-26T01:43:01.349286",
|
||
"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.02028754202183336,
|
||
"timestamp": "2025-06-26T01:42:57.933338",
|
||
"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.015933374990709126,
|
||
"timestamp": "2025-06-26T01:42:57.949328",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.01868062501307577,
|
||
"timestamp": "2025-06-26T01:42:57.968079",
|
||
"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方法。但实际使用了POST方法,因此不符合该标准。",
|
||
"duration_seconds": 3.011503000045195,
|
||
"timestamp": "2025-06-26T01:43:00.979579",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "该API的用途是地质单元列表查询,属于数据检索操作,根据合规性标准应使用GET方法。但实际使用了POST方法,因此不符合该标准。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。;规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。",
|
||
"duration_seconds": 0.07506479101721197,
|
||
"timestamp": "2025-06-26T01:43:01.054941",
|
||
"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.0315515409456566,
|
||
"timestamp": "2025-06-26T01:43:01.086704",
|
||
"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.01793349999934435,
|
||
"timestamp": "2025-06-26T01:43:01.104786",
|
||
"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.021163125056773424,
|
||
"timestamp": "2025-06-26T01:43:01.126087",
|
||
"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.021714958013035357,
|
||
"timestamp": "2025-06-26T01:43:01.148061",
|
||
"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.02806054102256894,
|
||
"timestamp": "2025-06-26T01:43:01.176259",
|
||
"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.01666104095056653,
|
||
"timestamp": "2025-06-26T01:43:01.192983",
|
||
"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.015099584008567035,
|
||
"timestamp": "2025-06-26T01:43:01.208211",
|
||
"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.016332833096385002,
|
||
"timestamp": "2025-06-26T01:43:01.224718",
|
||
"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,但实际为 17。",
|
||
"duration_seconds": 0.022221541963517666,
|
||
"timestamp": "2025-06-26T01:43:01.247135",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 17,
|
||
"response_body": {
|
||
"code": 17,
|
||
"message": "nisi",
|
||
"data": {
|
||
"total": 91,
|
||
"list": [
|
||
{
|
||
"dsid": "53",
|
||
"dataRegion": "labore nisi anim ea commodo",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "51",
|
||
"dataRegion": "occaecat",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "5",
|
||
"dataRegion": "veniam Lorem do reprehenderit",
|
||
"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,但实际为 64。",
|
||
"duration_seconds": 0.018755291937850416,
|
||
"timestamp": "2025-06-26T01:43:01.266050",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 64,
|
||
"response_body": {
|
||
"code": 64,
|
||
"message": "Ut dolore id",
|
||
"data": {
|
||
"total": 80,
|
||
"list": [
|
||
{
|
||
"dsid": "41",
|
||
"dataRegion": "do",
|
||
"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,但实际为 90。",
|
||
"duration_seconds": 0.02114787499886006,
|
||
"timestamp": "2025-06-26T01:43:01.287359",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 90,
|
||
"response_body": {
|
||
"code": 90,
|
||
"message": "ea",
|
||
"data": {
|
||
"total": 84,
|
||
"list": [
|
||
{
|
||
"dsid": "12",
|
||
"dataRegion": "fugiat mollit sint",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "27",
|
||
"dataRegion": "ut anim quis fugiat",
|
||
"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_4ncodp' (合法值为: ['AND', 'OR']) 时, 业务错误码应为 -1,但实际为 58。",
|
||
"duration_seconds": 0.017875583958812058,
|
||
"timestamp": "2025-06-26T01:43:01.305382",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 58,
|
||
"response_body": {
|
||
"code": 58,
|
||
"message": "nisi",
|
||
"data": {
|
||
"total": 10,
|
||
"list": [
|
||
{
|
||
"dsid": "13",
|
||
"dataRegion": "veniam ut mollit",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "78",
|
||
"dataRegion": "reprehenderit nulla velit ut sunt",
|
||
"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.018537541036494076,
|
||
"timestamp": "2025-06-26T01:43:01.324240",
|
||
"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.024670458980835974,
|
||
"timestamp": "2025-06-26T01:43:01.349051",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "PUT /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据修改",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 3.936722,
|
||
"start_time": "2025-06-26T01:43:01.349498",
|
||
"end_time": "2025-06-26T01:43:05.286220",
|
||
"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.018169416929595172,
|
||
"timestamp": "2025-06-26T01:43:01.368863",
|
||
"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.01895483396947384,
|
||
"timestamp": "2025-06-26T01:43:01.388040",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.01637358299922198,
|
||
"timestamp": "2025-06-26T01:43:01.404599",
|
||
"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": 3.5203711669892073,
|
||
"timestamp": "2025-06-26T01:43:04.925139",
|
||
"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.054893000051379204,
|
||
"timestamp": "2025-06-26T01:43:04.980265",
|
||
"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.034188791061751544,
|
||
"timestamp": "2025-06-26T01:43:05.014739",
|
||
"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.03618991607800126,
|
||
"timestamp": "2025-06-26T01:43:05.051720",
|
||
"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.020801709033548832,
|
||
"timestamp": "2025-06-26T01:43:05.072754",
|
||
"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.01614808407612145,
|
||
"timestamp": "2025-06-26T01:43:05.089021",
|
||
"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.020145124988630414,
|
||
"timestamp": "2025-06-26T01:43:05.109494",
|
||
"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.019489791011437774,
|
||
"timestamp": "2025-06-26T01:43:05.129170",
|
||
"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.021154875052161515,
|
||
"timestamp": "2025-06-26T01:43:05.150470",
|
||
"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.017417665920220315,
|
||
"timestamp": "2025-06-26T01:43:05.168170",
|
||
"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,但实际为 8。",
|
||
"duration_seconds": 0.017540000029839575,
|
||
"timestamp": "2025-06-26T01:43:05.185975",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 8,
|
||
"response_body": {
|
||
"code": 8,
|
||
"message": "laboris",
|
||
"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,但实际为 17。",
|
||
"duration_seconds": 0.017488916986621916,
|
||
"timestamp": "2025-06-26T01:43:05.203628",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 17,
|
||
"response_body": {
|
||
"code": 17,
|
||
"message": "non velit magna",
|
||
"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.018206082982942462,
|
||
"timestamp": "2025-06-26T01:43:05.222041",
|
||
"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.021992833935655653,
|
||
"timestamp": "2025-06-26T01:43:05.244322",
|
||
"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.022648834041319788,
|
||
"timestamp": "2025-06-26T01:43:05.267398",
|
||
"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,但实际为 57。",
|
||
"duration_seconds": 0.01800912502221763,
|
||
"timestamp": "2025-06-26T01:43:05.285889",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 57,
|
||
"response_body": {
|
||
"code": 57,
|
||
"message": "Ut irure esse labore",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "DELETE /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据删除",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 4.990025,
|
||
"start_time": "2025-06-26T01:43:05.286413",
|
||
"end_time": "2025-06-26T01:43:10.276438",
|
||
"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.01813283294904977,
|
||
"timestamp": "2025-06-26T01:43:05.305766",
|
||
"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.021227542078122497,
|
||
"timestamp": "2025-06-26T01:43:05.327355",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.016841790988110006,
|
||
"timestamp": "2025-06-26T01:43:05.344281",
|
||
"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用于删除] 不通过: DELETE方法通常用于删除资源,但根据提供的API信息,该接口需要主键id(query参数)和请求体(schema_request_body),这不符合DELETE方法的常见用法。通常DELETE不需要请求体,因此可能选择不合适的HTTP方法。",
|
||
"duration_seconds": 4.616323750000447,
|
||
"timestamp": "2025-06-26T01:43:09.960573",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "DELETE方法通常用于删除资源,但根据提供的API信息,该接口需要主键id(query参数)和请求体(schema_request_body),这不符合DELETE方法的常见用法。通常DELETE不需要请求体,因此可能选择不合适的HTTP方法。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。",
|
||
"duration_seconds": 0.05198345798999071,
|
||
"timestamp": "2025-06-26T01:43:10.012788",
|
||
"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.029660917003639042,
|
||
"timestamp": "2025-06-26T01:43:10.042769",
|
||
"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.01899816608056426,
|
||
"timestamp": "2025-06-26T01:43:10.062183",
|
||
"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.019850000040605664,
|
||
"timestamp": "2025-06-26T01:43:10.082360",
|
||
"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.01742095802910626,
|
||
"timestamp": "2025-06-26T01:43:10.100201",
|
||
"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.02048854110762477,
|
||
"timestamp": "2025-06-26T01:43:10.121095",
|
||
"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.01610720797907561,
|
||
"timestamp": "2025-06-26T01:43:10.137420",
|
||
"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.017918749945238233,
|
||
"timestamp": "2025-06-26T01:43:10.155764",
|
||
"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.01726020802743733,
|
||
"timestamp": "2025-06-26T01:43:10.173291",
|
||
"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,但实际为 72。",
|
||
"duration_seconds": 0.01484008296392858,
|
||
"timestamp": "2025-06-26T01:43:10.188314",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 72,
|
||
"response_body": {
|
||
"code": 72,
|
||
"message": "qui",
|
||
"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": "当请求体字段 'version' 类型不匹配时, 业务错误码应为 -1,但实际为 1。",
|
||
"duration_seconds": 0.024643791955895722,
|
||
"timestamp": "2025-06-26T01:43:10.213144",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 1,
|
||
"response_body": {
|
||
"code": 1,
|
||
"message": "Lorem",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.015927417087368667,
|
||
"timestamp": "2025-06-26T01:43:10.229263",
|
||
"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.014786250074394047,
|
||
"timestamp": "2025-06-26T01:43:10.244175",
|
||
"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.01598937506787479,
|
||
"timestamp": "2025-06-26T01:43:10.260485",
|
||
"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,但实际为 48。",
|
||
"duration_seconds": 0.01538370898924768,
|
||
"timestamp": "2025-06-26T01:43:10.276119",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 48,
|
||
"response_body": {
|
||
"code": 48,
|
||
"message": "officia nostrud in",
|
||
"data": false
|
||
}
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据添加",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 3.67712,
|
||
"start_time": "2025-06-26T01:43:10.276655",
|
||
"end_time": "2025-06-26T01:43:13.953775",
|
||
"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.018504375009797513,
|
||
"timestamp": "2025-06-26T01:43:10.296405",
|
||
"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.02039849990978837,
|
||
"timestamp": "2025-06-26T01:43:10.317069",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.016486374894157052,
|
||
"timestamp": "2025-06-26T01:43:10.333866",
|
||
"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方法,根据描述'地质单元数据添加',其语义与创建资源相符,因此符合POST方法的使用规范。",
|
||
"duration_seconds": 3.3163340829778463,
|
||
"timestamp": "2025-06-26T01:43:13.650375",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "该API使用了POST方法,根据描述'地质单元数据添加',其语义与创建资源相符,因此符合POST方法的使用规范。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。;规范中未找到响应码 200 或其类别(2XX, default)的匹配定义,跳过空数组与null的检查。",
|
||
"duration_seconds": 0.04554362501949072,
|
||
"timestamp": "2025-06-26T01:43:13.696238",
|
||
"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.02652800001669675,
|
||
"timestamp": "2025-06-26T01:43:13.722979",
|
||
"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.0240472920704633,
|
||
"timestamp": "2025-06-26T01:43:13.747444",
|
||
"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.023045208887197077,
|
||
"timestamp": "2025-06-26T01:43:13.770968",
|
||
"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.018366958014667034,
|
||
"timestamp": "2025-06-26T01:43:13.789852",
|
||
"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.015303124906495214,
|
||
"timestamp": "2025-06-26T01:43:13.805469",
|
||
"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.017553166951984167,
|
||
"timestamp": "2025-06-26T01:43:13.823441",
|
||
"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.015849624993279576,
|
||
"timestamp": "2025-06-26T01:43:13.839714",
|
||
"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.016650417004711926,
|
||
"timestamp": "2025-06-26T01:43:13.856601",
|
||
"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.01493462489452213,
|
||
"timestamp": "2025-06-26T01:43:13.871596",
|
||
"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,但实际为 23。",
|
||
"duration_seconds": 0.019562750007025898,
|
||
"timestamp": "2025-06-26T01:43:13.891294",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 23,
|
||
"response_body": {
|
||
"code": 23,
|
||
"message": "ut",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.015508624957874417,
|
||
"timestamp": "2025-06-26T01:43:13.907006",
|
||
"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.014622541959397495,
|
||
"timestamp": "2025-06-26T01:43:13.921789",
|
||
"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,但实际为 75。",
|
||
"duration_seconds": 0.015243584057316184,
|
||
"timestamp": "2025-06-26T01:43:13.937354",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 75,
|
||
"response_body": {
|
||
"code": 75,
|
||
"message": "pariatur proident est cupidatat",
|
||
"data": true
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.01624912500847131,
|
||
"timestamp": "2025-06-26T01:43:13.953730",
|
||
"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": 3.536406,
|
||
"start_time": "2025-06-26T01:43:13.953811",
|
||
"end_time": "2025-06-26T01:43:17.490217",
|
||
"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.016300834016874433,
|
||
"timestamp": "2025-06-26T01:43:13.970307",
|
||
"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.015849333023652434,
|
||
"timestamp": "2025-06-26T01:43:13.986298",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-SECURITY-002",
|
||
"test_case_name": "敏感字段加密检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "未在响应中找到需要检查的敏感字段。",
|
||
"duration_seconds": 0.015925624989904463,
|
||
"timestamp": "2025-06-26T01:43:14.002371",
|
||
"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方法为GET,其功能是查询地质单元详情,符合GET用于检索的语义。",
|
||
"duration_seconds": 3.151895167073235,
|
||
"timestamp": "2025-06-26T01:43:17.154359",
|
||
"validation_points": [
|
||
{
|
||
"criterion": "API应该使用正确的HTTP方法:GET用于检索,POST用于创建,PUT用于更新,DELETE用于删除",
|
||
"llm_reason": "该API使用的HTTP方法为GET,其功能是查询地质单元详情,符合GET用于检索的语义。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-RESTful-001",
|
||
"test_case_name": "核心命名与结构规范检查",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "模块名 'dms' 格式正确 (全小写/数字/中划线)。",
|
||
"duration_seconds": 0.058747208095155656,
|
||
"timestamp": "2025-06-26T01:43:17.213550",
|
||
"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.023829375044442713,
|
||
"timestamp": "2025-06-26T01:43:17.237631",
|
||
"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.022564541082829237,
|
||
"timestamp": "2025-06-26T01:43:17.260670",
|
||
"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.019240082940086722,
|
||
"timestamp": "2025-06-26T01:43:17.280353",
|
||
"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.02041066694073379,
|
||
"timestamp": "2025-06-26T01:43:17.301128",
|
||
"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.019265166949480772,
|
||
"timestamp": "2025-06-26T01:43:17.320870",
|
||
"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.02016604202799499,
|
||
"timestamp": "2025-06-26T01:43:17.341321",
|
||
"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.017957083065994084,
|
||
"timestamp": "2025-06-26T01:43:17.359724",
|
||
"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.017462208052165806,
|
||
"timestamp": "2025-06-26T01:43:17.377633",
|
||
"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.023909332929179072,
|
||
"timestamp": "2025-06-26T01:43:17.401802",
|
||
"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,但实际为 67。",
|
||
"duration_seconds": 0.018225334002636373,
|
||
"timestamp": "2025-06-26T01:43:17.420329",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 67,
|
||
"response_body": {
|
||
"code": 67,
|
||
"message": "sit ad",
|
||
"data": {
|
||
"total": 57,
|
||
"list": [
|
||
{
|
||
"dsid": "68",
|
||
"dataRegion": "est dolore consequat dolore tempor",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "52",
|
||
"dataRegion": "amet nulla ad cillum",
|
||
"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.017360249999910593,
|
||
"timestamp": "2025-06-26T01:43:17.437907",
|
||
"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_7p006a' (合法值为: ['AND', 'OR']) 时, 业务错误码应为 -1,但实际为 71。",
|
||
"duration_seconds": 0.016325167031027377,
|
||
"timestamp": "2025-06-26T01:43:17.454420",
|
||
"validation_points": [
|
||
{
|
||
"expected_code": -1,
|
||
"actual_code": 71,
|
||
"response_body": {
|
||
"code": 71,
|
||
"message": "reprehenderit",
|
||
"data": {
|
||
"total": 99,
|
||
"list": [
|
||
{
|
||
"dsid": "70",
|
||
"dataRegion": "deserunt in Lorem officia tempor",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "40",
|
||
"dataRegion": "incididunt cupidatat Excepteur",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "77",
|
||
"dataRegion": "eu fugiat",
|
||
"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.015615208889357746,
|
||
"timestamp": "2025-06-26T01:43:17.470373",
|
||
"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.0194057080661878,
|
||
"timestamp": "2025-06-26T01:43:17.489973",
|
||
"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.04",
|
||
"start_time": "2025-06-26T01:43:17",
|
||
"end_time": "2025-06-26T01:43:17",
|
||
"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-26T01:43:17+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_1750873397_a11f93",
|
||
"dataRegion": "Feature_1750873397"
|
||
}
|
||
]
|
||
},
|
||
"body": {
|
||
"version": "1.0.0",
|
||
"data": [
|
||
{
|
||
"wellCommonName": "TestResource_1750873397_a11f93",
|
||
"dataRegion": "Feature_1750873397"
|
||
}
|
||
]
|
||
},
|
||
"data": null,
|
||
"timeout": 30
|
||
},
|
||
"extracted_outputs": {},
|
||
"context_after_step_summary": {
|
||
"unique_resource_name": "TestResource_1750873397_a11f93",
|
||
"updated_resource_name": "TestResource_1750873397_a11f93_UPDATED",
|
||
"unique_feature_value": "Feature_1750873397",
|
||
"updated_feature_value": "Feature_1750873397_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_1750873397_a11f93' (field: wellCommonName) not found in list at path 'data.list'.",
|
||
"duration_seconds": "0.0000",
|
||
"timestamp": "2025-06-26T01:43:17+0800",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "状态码匹配 (200)."
|
||
},
|
||
{
|
||
"passed": false,
|
||
"message": "Resource not found: Name 'TestResource_1750873397_a11f93' (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_1750873397_a11f93"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"body": {
|
||
"isSearchCount": true,
|
||
"query": {
|
||
"fields": [
|
||
"dsid",
|
||
"wellCommonName",
|
||
"dataRegion"
|
||
],
|
||
"filter": {
|
||
"key": "wellCommonName",
|
||
"symbol": "=",
|
||
"realValue": [
|
||
"TestResource_1750873397_a11f93"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"data": null,
|
||
"timeout": 30
|
||
},
|
||
"extracted_outputs": {},
|
||
"context_after_step_summary": {
|
||
"unique_resource_name": "TestResource_1750873397_a11f93",
|
||
"updated_resource_name": "TestResource_1750873397_a11f93_UPDATED",
|
||
"unique_feature_value": "Feature_1750873397",
|
||
"updated_feature_value": "Feature_1750873397_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_1750873397_a11f93",
|
||
"updated_resource_name": "TestResource_1750873397_a11f93_UPDATED",
|
||
"unique_feature_value": "Feature_1750873397",
|
||
"updated_feature_value": "Feature_1750873397_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": []
|
||
} |