-
Notifications
You must be signed in to change notification settings - Fork 136
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat/waf #2111
Conversation
…der-tencentcloud into feat/waf
…der-tencentcloud into feat/waf
…der-tencentcloud into feat/waf
…der-tencentcloud into feat/waf
logId = getLogId(contextNil) | ||
ctx = context.WithValue(context.TODO(), logIdKey, logId) | ||
service = WafService{client: meta.(*TencentCloudClient).apiV3Conn} | ||
tLS []*waf.TLSVersion |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个变量命名有点奇怪
|
||
log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) | ||
|
||
if response == nil || len(response.Response.Ciphers) < 1 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
response.Response 可能为空吗
|
||
log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) | ||
|
||
if len(response.Response.RuleList) < 1 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
是否有可能 response.Response 为 nil 或者空
Steps: []resource.TestStep{ | ||
{ | ||
Config: testAccWafClbDomain, | ||
Check: resource.ComposeTestCheckFunc( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
e2e测试用例最好每个字段都检查下?
}, | ||
{ | ||
Config: testAccWafClbDomainUpdate, | ||
Check: resource.ComposeTestCheckFunc( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
同上,每个字段都检查下?
return err | ||
} | ||
|
||
ruleId := *response.Response.RuleId |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
response.Response 是否可能为空
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
先合入,有几个小点,下次调整
feat/waf