Skip to content

Commit

Permalink
test: fix case for recommend url
Browse files Browse the repository at this point in the history
  • Loading branch information
JacksonTian authored and peze committed Oct 12, 2023
1 parent b14dfdf commit f5d0fb0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion openapi/commando_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,9 @@ func Test_main(t *testing.T) {
args = []string{"ecs", "DescribeRegions"}
err = command.main(ctx, args)
assert.NotNil(t, err)
assert.True(t, strings.Contains(err.Error(), "SDK.ServerError\nErrorCode: InvalidAction.NotFound\nRecommend: https://api.aliyun.com/troubleshoot?q=InvalidAction.NotFound&product=Ecs\nRequestId:"))
assert.True(t, strings.Contains(err.Error(), "SDK.ServerError\nErrorCode: InvalidAction.NotFound\n"))
assert.True(t, strings.Contains(err.Error(), "Recommend: https://api.aliyun.com/troubleshoot?q=InvalidAction.NotFound&product=Ecs&requestId="))
assert.True(t, strings.Contains(err.Error(), "RequestId: "))

ctx.Flags().Get("force").SetAssigned(false)
ctx.Flags().Get("version").SetAssigned(false)
Expand Down

0 comments on commit f5d0fb0

Please sign in to comment.