File tree Expand file tree Collapse file tree 4 files changed +0
-152
lines changed
controlplane/kubeconfiggen Expand file tree Collapse file tree 4 files changed +0
-152
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ package controller
33import (
44 "context"
55 "errors"
6- "log"
76 "os"
87 "testing"
98 "time"
@@ -33,13 +32,9 @@ import (
3332 "github.com/openmcp-project/control-plane-operator/internal/schemes"
3433 "github.com/openmcp-project/control-plane-operator/pkg/controlplane/kubeconfiggen"
3534 "github.com/openmcp-project/control-plane-operator/pkg/controlplane/secretresolver"
36- envtestutil "github.com/openmcp-project/control-plane-operator/pkg/utils/envtest"
3735)
3836
3937func TestMain (m * testing.M ) {
40- if err := envtestutil .Install (); err != nil {
41- log .Fatalln (err )
42- }
4338 os .Exit (m .Run ())
4439}
4540
Original file line number Diff line number Diff line change @@ -4,13 +4,11 @@ import (
44 "bytes"
55 "context"
66 "io"
7- "log"
87 "os"
98 "testing"
109 "time"
1110
1211 "github.com/openmcp-project/control-plane-operator/api/v1beta1"
13- envtestutil "github.com/openmcp-project/control-plane-operator/pkg/utils/envtest"
1412 "github.com/stretchr/testify/assert"
1513 corev1 "k8s.io/api/core/v1"
1614 metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
3230)
3331
3432func TestMain (m * testing.M ) {
35- if err := envtestutil .Install (); err != nil {
36- log .Fatalln (err )
37- }
3833 os .Exit (m .Run ())
3934}
4035
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11package envtest
22
33import (
4- "path/filepath"
54 "testing"
65
76 "github.com/stretchr/testify/assert"
87 k8senvtest "sigs.k8s.io/controller-runtime/pkg/envtest"
98)
109
11- func Test_findMakefile (t * testing.T ) {
12- actual , err := findMakefile ("." )
13- assert .NoError (t , err )
14-
15- expected , err := filepath .Abs ("../../../Makefile" )
16- assert .NoError (t , err )
17- assert .Equal (t , expected , actual )
18- }
19-
2010func Test_Install (t * testing.T ) {
21- assert .NoError (t , Install ())
2211 testEnv := & k8senvtest.Environment {}
2312 _ , err := testEnv .Start ()
2413 assert .NoError (t , err )
You can’t perform that action at this time.
0 commit comments