-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
scorecard - add PATCH to list of methods in scorecard CR update test #2509
scorecard - add PATCH to list of methods in scorecard CR update test #2509
Conversation
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.
/lgtm
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.
Missing the CHANGELOG entry only.
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.
One nit. Otherwise looks good.
/lgtm
@@ -170,15 +170,16 @@ func (t *WritingIntoCRsHasEffectTest) Run(ctx context.Context) *schelpers.TestRe | |||
if !ok { | |||
continue | |||
} | |||
if method == "PUT" || method == "POST" { | |||
|
|||
if method == "PUT" || method == "POST" || method == "PATCH" { |
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.
Non-blocking nit: change these to http.MethodPut
, http.MethodPost
, etc.
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.
fixed, good catch!
New changes are detected. LGTM label has been removed. |
Description of the change:
with this change, the scorecard basic test (updatecr) will add PATCH to the list of http methods checked from the proxy log, previously only PUT and POST were checked and if found would cause the scorecard test to pass.
Motivation for the change:
this issue arises when you have an operator that is NOT written with the SDK AND when you want that operator to pass the scorecard basic-test UpdateCR test. With this change, the proxy when it logs a PATCH http method, will cause the operator basic test (update cr) to detect the PATCH and pass the test.