Skip to content

Commit e1edfdc

Browse files
erikgbinteon
authored andcommitted
Don't check spec for status sub-resource requests
Signed-off-by: Erik Godding Boye <egboye@gmail.com>
1 parent 463a303 commit e1edfdc

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

pkg/controller/test/actions.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,10 @@ func (a *action) Matches(act coretesting.Action) error {
107107

108108
return testutil.Diff(expObj, gotObj,
109109
cmp.FilterPath(func(p cmp.Path) bool {
110+
if p.String() == "Spec" {
111+
// Filter out spec if this action is for the status sub-resource
112+
return a.action.GetSubresource() == "status"
113+
}
110114
if p.String() == "TypeMeta.APIVersion" {
111115
return true
112116
}

0 commit comments

Comments
 (0)