controller: add non-exist node test case

This commit is contained in:
Paco Xu
2022-11-01 18:12:32 +08:00
parent ccf57ba09d
commit 2557b35202
2 changed files with 28 additions and 1 deletions

View File

@@ -152,7 +152,7 @@ func (m *FakeNodeHandler) Get(ctx context.Context, name string, opts metav1.GetO
return &nodeCopy, nil
}
}
return nil, nil
return nil, apierrors.NewNotFound(schema.GroupResource{Resource: "nodes"}, name)
}
func (m *FakeNodeHandler) runAsyncCalls() {