mirror of
https://github.com/1Password/onepassword-operator.git
synced 2025-10-21 15:08:06 +00:00
Move testhelper
package to pkg
so it can be installed as dependency in secrets injector repo
This commit is contained in:
@@ -8,7 +8,7 @@ import (
|
|||||||
//nolint:staticcheck // ST1001
|
//nolint:staticcheck // ST1001
|
||||||
. "github.com/onsi/gomega"
|
. "github.com/onsi/gomega"
|
||||||
|
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/system"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/system"
|
||||||
)
|
)
|
||||||
|
|
||||||
// LoadImageToKind loads a local docker image to the Kind cluster
|
// LoadImageToKind loads a local docker image to the Kind cluster
|
@@ -11,8 +11,8 @@ import (
|
|||||||
//nolint:staticcheck // ST1001
|
//nolint:staticcheck // ST1001
|
||||||
. "github.com/onsi/gomega"
|
. "github.com/onsi/gomega"
|
||||||
|
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/defaults"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/defaults"
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/system"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/system"
|
||||||
)
|
)
|
||||||
|
|
||||||
func CreateSecretFromEnvVar(envVar, secretName string) {
|
func CreateSecretFromEnvVar(envVar, secretName string) {
|
@@ -8,7 +8,7 @@ import (
|
|||||||
//nolint:staticcheck // ST1001
|
//nolint:staticcheck // ST1001
|
||||||
. "github.com/onsi/gomega"
|
. "github.com/onsi/gomega"
|
||||||
|
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/system"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/system"
|
||||||
)
|
)
|
||||||
|
|
||||||
func BuildOperatorImage() {
|
func BuildOperatorImage() {
|
@@ -12,3 +12,22 @@ func TestE2E(t *testing.T) {
|
|||||||
RegisterFailHandler(Fail)
|
RegisterFailHandler(Fail)
|
||||||
RunSpecs(t, "onepassword-operator e2e suite")
|
RunSpecs(t, "onepassword-operator e2e suite")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//By("create onepassword-token secret")
|
||||||
|
//connectToken, _ := os.LookupEnv("OP_CONNECT_TOKEN")
|
||||||
|
//Expect(connectToken).NotTo(BeEmpty())
|
||||||
|
//output := exec.Command("kubectl", "-n", namespace, "create", "secret", "generic", "onepassword-token", "--from-literal=token="+connectToken)
|
||||||
|
//_, err = utils.Run(output)
|
||||||
|
//ExpectWithOffset(1, err).NotTo(HaveOccurred())
|
||||||
|
|
||||||
|
//It("Secret is updated after POOLING_INTERVAL", func() {
|
||||||
|
// // TODO: implement
|
||||||
|
//})
|
||||||
|
//
|
||||||
|
//It("Secret with `ignore-secret` annotation is not updated", func() {
|
||||||
|
// // TODO: implement
|
||||||
|
//})
|
||||||
|
//
|
||||||
|
//It("Deployment not auto restarts when ", func() {
|
||||||
|
// // TODO: implement
|
||||||
|
//})
|
||||||
|
@@ -6,10 +6,10 @@ import (
|
|||||||
. "github.com/onsi/ginkgo/v2"
|
. "github.com/onsi/ginkgo/v2"
|
||||||
. "github.com/onsi/gomega"
|
. "github.com/onsi/gomega"
|
||||||
|
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/kind"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/kind"
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/kube"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/kube"
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/operator"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/operator"
|
||||||
"github.com/1Password/onepassword-operator/test/testhelper/system"
|
"github.com/1Password/onepassword-operator/pkg/testhelper/system"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
Reference in New Issue
Block a user