@@ -36,8 +36,6 @@ import (
3636 "sigs.k8s.io/controller-runtime/pkg/manager"
3737 "sigs.k8s.io/controller-runtime/pkg/metrics/server"
3838
39- consolev1alpha "github.com/openshift/api/console/v1alpha1"
40-
4139 remediationv1alpha1 "github.com/medik8s/node-healthcheck-operator/api/v1alpha1"
4240)
4341
@@ -65,13 +63,7 @@ var _ = BeforeSuite(func() {
6563
6664 By ("bootstrapping test environment" )
6765 testEnv = & envtest.Environment {
68- CRDInstallOptions : envtest.CRDInstallOptions {
69- Paths : []string {
70- filepath .Join (".." , ".." , "vendor" , "github.com" , "openshift" , "api" , "console" , "v1alpha1" ),
71- filepath .Join (".." , ".." , "config" , "crd" , "bases" ),
72- },
73- ErrorIfPathMissing : true ,
74- },
66+ CRDDirectoryPaths : []string {filepath .Join (".." , ".." , "config" , "crd" , "bases" )},
7567 }
7668
7769 var err error
@@ -80,8 +72,8 @@ var _ = BeforeSuite(func() {
8072 Expect (cfg ).NotTo (BeNil ())
8173
8274 scheme .AddToScheme (scheme .Scheme )
83- Expect ( remediationv1alpha1 .AddToScheme (scheme .Scheme )). NotTo ( HaveOccurred () )
84- Expect (consolev1alpha . AddToScheme ( scheme . Scheme ) ).NotTo (HaveOccurred ())
75+ err = remediationv1alpha1 .AddToScheme (scheme .Scheme )
76+ Expect (err ).NotTo (HaveOccurred ())
8577
8678 k8sClient , err = client .New (cfg , client.Options {Scheme : scheme .Scheme })
8779 Expect (err ).NotTo (HaveOccurred ())
0 commit comments