Skip to content

Commit 812d184

Browse files
Merge pull request #1147 from dinhxuanvu/unit-fix
fix(unit): Fix minor unit test bug and update local cluster to k8s 1.16
2 parents ace9808 + a401ca2 commit 812d184

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

pkg/controller/operators/catalog/operator_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,7 @@ func TestSyncCatalogSources(t *testing.T) {
512512
Namespace: "cool-namespace",
513513
UID: types.UID("configmap-uid"),
514514
ResourceVersion: "resource-version",
515-
LastUpdateTime: now,
515+
LastUpdateTime: now,
516516
},
517517
RegistryServiceStatus: nil,
518518
},
@@ -854,7 +854,7 @@ func NewFakeOperator(ctx context.Context, namespace string, watchedNamespaces []
854854
var sharedInformers []cache.SharedIndexInformer
855855
for _, ns := range watchedNamespaces {
856856
if ns != namespace {
857-
_, err := opClientFake.KubernetesInterface().CoreV1().Namespaces().Create(&corev1.Namespace{ObjectMeta: metav1.ObjectMeta{Name: namespace}})
857+
_, err := opClientFake.KubernetesInterface().CoreV1().Namespaces().Create(&corev1.Namespace{ObjectMeta: metav1.ObjectMeta{Name: ns}})
858858
if err != nil {
859859
return nil, err
860860
}
@@ -917,7 +917,7 @@ func NewFakeOperator(ctx context.Context, namespace string, watchedNamespaces []
917917
reconciler: config.reconciler,
918918
clientAttenuator: scoped.NewClientAttenuator(logger, &rest.Config{}, opClientFake, clientFake),
919919
serviceAccountQuerier: scoped.NewUserDefinedServiceAccountQuerier(logger, clientFake),
920-
catsrcQueueSet: queueinformer.NewEmptyResourceQueueSet(),
920+
catsrcQueueSet: queueinformer.NewEmptyResourceQueueSet(),
921921
}
922922
op.sources = grpc.NewSourceStore(config.logger, 1*time.Second, 5*time.Second, op.syncSourceState)
923923
if op.reconciler == nil {

scripts/build_local.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
set -e
77

88
if [ -z "$NO_MINIKUBE" ]; then
9-
pgrep -f "[m]inikube" >/dev/null || minikube start --kubernetes-version="v1.14.2" --extra-config=apiserver.v=4 || { echo 'Cannot start minikube.'; exit 1; }
9+
pgrep -f "[m]inikube" >/dev/null || minikube start --kubernetes-version="v1.16.2" --extra-config=apiserver.v=4 || { echo 'Cannot start minikube.'; exit 1; }
1010
eval "$(minikube docker-env)" || { echo 'Cannot switch to minikube docker'; exit 1; }
1111
kubectl config use-context minikube
1212
fi

0 commit comments

Comments
 (0)