云端事件:修复实例通知并移出 LaunchInstance 回传

This commit is contained in:
2026-07-17 16:52:49 +08:00
parent 882eeade1e
commit 6cf9465fea
6 changed files with 131 additions and 13 deletions
+8
View File
@@ -308,6 +308,14 @@ func TestParseLogEvent(t *testing.T) {
wantType: "x",
wantOutcome: "失败",
},
{
name: "failed with response 判失败并提取错误码",
payload: `{"type":"com.oraclecloud.computeApi.LaunchInstance.begin","data":{
"message":"LaunchInstance failed with response 'NotAuthorizedOrNotFound'"}}`,
wantType: "com.oraclecloud.computeApi.LaunchInstance.begin",
wantOutcome: "失败",
wantDetail: "NotAuthorizedOrNotFound",
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {