-
Notifications
You must be signed in to change notification settings - Fork 28
Avoid name conflict by using deployment+delimiter+container as the key (#159) #161
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.
@houshengbo: 0 warnings.
In response to this:
Issue to be fixed
Fixes #
Proposed Changes
Release Note
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: houshengbo The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
59c49ab
to
5e56c24
Compare
The following is the coverage report on the affected files.
|
overrideImage := registry.Override[containerName] | ||
func getNewImage(registry *eventingv1alpha1.Registry, containerName, deploymentName string) string { | ||
overrideImage := registry.Override[deploymentName+delimiter+containerName] | ||
if overrideImage == "" { |
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.
please add a test where override for "deploymentName+delimiter+containerName" and "containerName" is specified, and that "deploymentName+delimiter+containerName" wins out, that is to verify that deploymentName takes precedence over just containerName
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.
That is what exactly the test cases in image_test.go is doing:
OverrideWithDeploymentContainer, OverridePartialWithDeploymentContainer, OverrideWithDeploymentName
They respectively check overriding both of two containers, overriding one container, and using deploymentName+delimiter+containerName
only.
Let me merge it first, to catch up the incoming patch release in 30 mins. |
Cherry-pick of 044d9c4