904 lines
36 KiB
JSON
904 lines
36 KiB
JSON
{
|
||
"summary_metadata": {
|
||
"start_time": "2025-05-27T15:59:36.146680",
|
||
"end_time": "2025-05-27T15:59:37.145441",
|
||
"duration_seconds": "1.00"
|
||
},
|
||
"endpoint_stats": {
|
||
"total_defined": 6,
|
||
"total_tested": 6,
|
||
"passed": 0,
|
||
"failed": 6,
|
||
"partial_success": 0,
|
||
"error": 0,
|
||
"skipped": 0,
|
||
"success_rate_percentage": "0.00"
|
||
},
|
||
"test_case_stats": {
|
||
"total_applicable": 42,
|
||
"total_executed": 42,
|
||
"passed": 24,
|
||
"failed": 18,
|
||
"error_in_execution": 0,
|
||
"skipped_during_endpoint_execution": 0,
|
||
"success_rate_percentage": "57.14"
|
||
},
|
||
"detailed_results": [
|
||
{
|
||
"endpoint_id": "POST /api/dms/{dms_instance_code}/v1/message/push/{schema}/{version}",
|
||
"endpoint_name": "数据推送接口",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 0.225553,
|
||
"start_time": "2025-05-27T15:59:36.152754",
|
||
"end_time": "2025-05-27T15:59:36.378307",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.08939158311113715,
|
||
"timestamp": "2025-05-27T15:59:36.242352",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.024271792033687234,
|
||
"timestamp": "2025-05-27T15:59:36.266695",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.028337875148281455,
|
||
"timestamp": "2025-05-27T15:59:36.295103",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code 4001 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。",
|
||
"duration_seconds": 0.0205999577883631,
|
||
"timestamp": "2025-05-27T15:59:36.315778",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code 4001 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'isSearchCount' 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '79'.",
|
||
"duration_seconds": 0.023709540953859687,
|
||
"timestamp": "2025-05-27T15:59:36.339544",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 79,
|
||
"message": "velit",
|
||
"data": {
|
||
"total": 44,
|
||
"list": [
|
||
{
|
||
"dsid": "76",
|
||
"dataRegion": "dolor qui",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "57",
|
||
"dataRegion": "dolore consectetur",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_field": "body.isSearchCount"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.021138250129297376,
|
||
"timestamp": "2025-05-27T15:59:36.360740",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.017457917099818587,
|
||
"timestamp": "2025-05-27T15:59:36.378260",
|
||
"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": 0.135739,
|
||
"start_time": "2025-05-27T15:59:36.378342",
|
||
"end_time": "2025-05-27T15:59:36.514081",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.02148370910435915,
|
||
"timestamp": "2025-05-27T15:59:36.399911",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.01699324999935925,
|
||
"timestamp": "2025-05-27T15:59:36.416954",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.019600082887336612,
|
||
"timestamp": "2025-05-27T15:59:36.436603",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code 4001 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当查询参数 'pageNo' (路径: 'pageNo') 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '23'.",
|
||
"duration_seconds": 0.017866916954517365,
|
||
"timestamp": "2025-05-27T15:59:36.454517",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 23,
|
||
"message": "veniam non sit aute",
|
||
"data": {
|
||
"total": 91,
|
||
"list": [
|
||
{
|
||
"dsid": "89",
|
||
"dataRegion": "cupidatat nostrud labore sint elit",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "71",
|
||
"dataRegion": "incididunt sed",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "56",
|
||
"dataRegion": "nisi cupidatat anim enim",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_param": "pageNo"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code 4001 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'isSearchCount' 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '33'.",
|
||
"duration_seconds": 0.022887999890372157,
|
||
"timestamp": "2025-05-27T15:59:36.477483",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 33,
|
||
"message": "labore dolore nulla ut ullamco",
|
||
"data": {
|
||
"total": 76,
|
||
"list": [
|
||
{
|
||
"dsid": "91",
|
||
"dataRegion": "amet cillum ex",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
},
|
||
{
|
||
"dsid": "96",
|
||
"dataRegion": "cupidatat elit eu ut Ut",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_field": "body.isSearchCount"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.019537542015314102,
|
||
"timestamp": "2025-05-27T15:59:36.497081",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.016892499988898635,
|
||
"timestamp": "2025-05-27T15:59:36.514032",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "PUT /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据修改",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 0.148082,
|
||
"start_time": "2025-05-27T15:59:36.514113",
|
||
"end_time": "2025-05-27T15:59:36.662195",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.014676582999527454,
|
||
"timestamp": "2025-05-27T15:59:36.528899",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 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.018297625007107854,
|
||
"timestamp": "2025-05-27T15:59:36.547341",
|
||
"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-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.01733270799741149,
|
||
"timestamp": "2025-05-27T15:59:36.564746",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code 4001 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当查询参数 'id' (路径: 'id') 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '49'.",
|
||
"duration_seconds": 0.020647957921028137,
|
||
"timestamp": "2025-05-27T15:59:36.585445",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 49,
|
||
"message": "dolore ullamco in fugiat nulla",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_param": "id"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code 4001 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'id' 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '7'.",
|
||
"duration_seconds": 0.0333723749499768,
|
||
"timestamp": "2025-05-27T15:59:36.618874",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 7,
|
||
"message": "esse nisi",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_field": "body.id"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "当移除必填请求体字段 'id' 时,API响应了状态码 200 (非主要预期HTTP状态 [400, 422],但为4xx客户端错误), 且响应体中包含预期的业务错误码 '4003' (字段: 'code').",
|
||
"duration_seconds": 0.02694650017656386,
|
||
"timestamp": "2025-05-27T15:59:36.645867",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "当移除必填请求体字段 'id' 时,API响应了状态码 200 (非主要预期HTTP状态 [400, 422],但为4xx客户端错误), 且响应体中包含预期的业务错误码 '4003' (字段: 'code')."
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填查询参数 'id' 时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4003'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '10'.",
|
||
"duration_seconds": 0.01623179204761982,
|
||
"timestamp": "2025-05-27T15:59:36.662156",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 10,
|
||
"message": "nulla sunt incididunt",
|
||
"data": true
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4003",
|
||
"removed_param": "query.id"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "DELETE /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据删除",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 0.140463,
|
||
"start_time": "2025-05-27T15:59:36.662224",
|
||
"end_time": "2025-05-27T15:59:36.802687",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.01605641609057784,
|
||
"timestamp": "2025-05-27T15:59:36.678387",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 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.02132979198358953,
|
||
"timestamp": "2025-05-27T15:59:36.699777",
|
||
"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-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.020369833102449775,
|
||
"timestamp": "2025-05-27T15:59:36.720223",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code 4001 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当查询参数 'id' (路径: 'id') 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '11'.",
|
||
"duration_seconds": 0.025968082947656512,
|
||
"timestamp": "2025-05-27T15:59:36.746338",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 11,
|
||
"message": "tempor",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_param": "id"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code 4001 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'version' 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '88'.",
|
||
"duration_seconds": 0.018293292028829455,
|
||
"timestamp": "2025-05-27T15:59:36.764772",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 88,
|
||
"message": "consectetur fugiat in amet",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_field": "body.version"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.01737149991095066,
|
||
"timestamp": "2025-05-27T15:59:36.782236",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填查询参数 'id' 时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4003'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '84'.",
|
||
"duration_seconds": 0.02023683302104473,
|
||
"timestamp": "2025-05-27T15:59:36.802601",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 84,
|
||
"message": "sed",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4003",
|
||
"removed_param": "query.id"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"endpoint_id": "POST /api/dms/{dms_instance_code}/v1/cd_geo_unit",
|
||
"endpoint_name": "地质单元数据添加",
|
||
"overall_status": "失败",
|
||
"duration_seconds": 0.145649,
|
||
"start_time": "2025-05-27T15:59:36.802749",
|
||
"end_time": "2025-05-27T15:59:36.948398",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.029517250135540962,
|
||
"timestamp": "2025-05-27T15:59:36.832514",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 200。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.021417916985228658,
|
||
"timestamp": "2025-05-27T15:59:36.854163",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "Schema验证步骤完成(未发现问题,或schema不适用/未为此响应定义)。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"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.021938083926215768,
|
||
"timestamp": "2025-05-27T15:59:36.876207",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code 4001 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。",
|
||
"duration_seconds": 0.01749758399091661,
|
||
"timestamp": "2025-05-27T15:59:36.893958",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code 4001 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'version' 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '7'.",
|
||
"duration_seconds": 0.018638750072568655,
|
||
"timestamp": "2025-05-27T15:59:36.912695",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 7,
|
||
"message": "Ut",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_field": "body.version"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "失败",
|
||
"message": "当移除必填请求体字段 'data.0.bsflag' 时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4003'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '82'.",
|
||
"duration_seconds": 0.017378374934196472,
|
||
"timestamp": "2025-05-27T15:59:36.930215",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 82,
|
||
"message": "Duis dolor reprehenderit Ut",
|
||
"data": false
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4003",
|
||
"removed_field": "body.data.0.bsflag"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.017817334039136767,
|
||
"timestamp": "2025-05-27T15:59:36.948213",
|
||
"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": 0.196579,
|
||
"start_time": "2025-05-27T15:59:36.948615",
|
||
"end_time": "2025-05-27T15:59:37.145194",
|
||
"executed_test_cases": [
|
||
{
|
||
"test_case_id": "TC-STATUS-001",
|
||
"test_case_name": "基本状态码 200 检查",
|
||
"test_case_severity": "严重",
|
||
"status": "通过",
|
||
"message": "响应状态码为 200,符合预期 200。",
|
||
"duration_seconds": 0.021936375182121992,
|
||
"timestamp": "2025-05-27T15:59:36.971324",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "响应状态码为 200,符合预期 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.02449154108762741,
|
||
"timestamp": "2025-05-27T15:59:36.996017",
|
||
"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-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.019439749885350466,
|
||
"timestamp": "2025-05-27T15:59:37.015766",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-QUERY",
|
||
"test_case_name": "Error Code 4001 - Query Parameter Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "通过",
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。",
|
||
"duration_seconds": 0.022281917044892907,
|
||
"timestamp": "2025-05-27T15:59:37.038259",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在查询参数中未找到合适的字段来测试类型不匹配。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4001-BODY",
|
||
"test_case_name": "Error Code 4001 - Request Body Type Mismatch Validation",
|
||
"test_case_severity": "中",
|
||
"status": "失败",
|
||
"message": "当请求体字段 'isSearchCount' 类型不匹配时,期望API返回状态码在 [400, 422] 中,或返回4xx客户端错误且业务码为 '4001'. 实际收到状态码 200. 响应体中的业务码 ('code') 为 '16'.",
|
||
"duration_seconds": 0.030999291921034455,
|
||
"timestamp": "2025-05-27T15:59:37.069406",
|
||
"validation_points": [
|
||
{
|
||
"status_code": 200,
|
||
"response_body": {
|
||
"code": 16,
|
||
"message": "sed",
|
||
"data": {
|
||
"total": 38,
|
||
"list": [
|
||
{
|
||
"dsid": "47",
|
||
"dataRegion": "non aliquip eu anim",
|
||
"gasReleaseMon": null,
|
||
"gasReleaseYear": null,
|
||
"releaseGasCum": null
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"expected_http_status_codes": [
|
||
400,
|
||
422
|
||
],
|
||
"expected_business_code": "4001",
|
||
"mismatched_field": "body.isSearchCount"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-BODY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Request Body Field Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。",
|
||
"duration_seconds": 0.028919625096023083,
|
||
"timestamp": "2025-05-27T15:59:37.098382",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填请求体字段用于移除测试。"
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"test_case_id": "TC-ERROR-4003-QUERY",
|
||
"test_case_name": "Error Code 4003 - Missing Required Query Parameter Validation",
|
||
"test_case_severity": "高",
|
||
"status": "通过",
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。",
|
||
"duration_seconds": 0.046320749912410975,
|
||
"timestamp": "2025-05-27T15:59:37.145055",
|
||
"validation_points": [
|
||
{
|
||
"passed": true,
|
||
"message": "跳过测试:在API规范中未找到合适的必填查询参数用于移除测试。"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
}
|
||
]
|
||
} |