Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR was initially to write a test for the
ensureNamespaces
func…
…tion, not to be confused with the `ensureNamespace` test I have in this commit. Upon testing `ensureNamespaces`, I think I've come across a few bugs. This function itself makes a call to `ensureNamespace` and it seems like there is potentially a scoping issue with where `err` is being set. It is my understanding that the following pattern: if err := something(); err != nil { } implies that this particular error is available within the scope locally. You can test out the differece by reverting the small change made in `mover.go` to see the different in behaviour. `ensureNamespaces` still needs a test written. Simplified test code to be more readable As per the kind suggestions, I have made changes to reflect those comments in this commit. Update cmd/clusterctl/client/cluster/mover.go Co-authored-by: Vince Prignano <vince@vincepri.com> Updated misleading comment We're no longer passing extra params here. Updated comment again Removed TypeMeta in namespace
- Loading branch information