Skip to content

Commit

Permalink
Update test/e2e/atlas/operator_helper_test.go
Browse files Browse the repository at this point in the history
Co-authored-by: Gustavo Bazan <[email protected]>
  • Loading branch information
s-urbaniak and gssbzn committed Nov 27, 2023
1 parent 3b4d903 commit 070e846
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 21 deletions.
20 changes: 0 additions & 20 deletions test/e2e/atlas/kubernetes_config_generate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1116,26 +1116,6 @@ func defaultMaintenanceWindowAlertConfigs(project *akov2.AtlasProject, dictionar
SMSEnabled: pointer.Get(false),
TypeName: "GROUP",
Roles: []string{"GROUP_OWNER"},
APITokenRef: akov2common.ResourceRefNamespaced{
Name: resources.NormalizeAtlasName(fmt.Sprintf("%s-api-token-%d", project.Name, i), dictionary),
Namespace: project.Namespace,
},
DatadogAPIKeyRef: akov2common.ResourceRefNamespaced{
Name: resources.NormalizeAtlasName(fmt.Sprintf("%s-datadog-api-key-%d", project.Name, i), dictionary),
Namespace: project.Namespace,
},
OpsGenieAPIKeyRef: akov2common.ResourceRefNamespaced{
Name: resources.NormalizeAtlasName(fmt.Sprintf("%s-ops-genie-api-key-%d", project.Name, i), dictionary),
Namespace: project.Namespace,
},
ServiceKeyRef: akov2common.ResourceRefNamespaced{
Name: resources.NormalizeAtlasName(fmt.Sprintf("%s-service-key-%d", project.Name, i), dictionary),
Namespace: project.Namespace,
},
VictorOpsSecretRef: akov2common.ResourceRefNamespaced{
Name: resources.NormalizeAtlasName(fmt.Sprintf("%s-victor-ops-credentials-%d", project.Name, i), dictionary),
Namespace: project.Namespace,
},
},
}
}
Expand Down
3 changes: 2 additions & 1 deletion test/e2e/atlas/operator_helper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import (
"testing"
"time"

"github.com/mongodb/mongodb-atlas-cli/internal/pointer"
akov2 "github.com/mongodb/mongodb-atlas-kubernetes/v2/pkg/api/v1"
akov2toptr "github.com/mongodb/mongodb-atlas-kubernetes/v2/pkg/util/toptr"
appsv1 "k8s.io/api/apps/v1"
Expand Down Expand Up @@ -158,7 +159,7 @@ func (oh *operatorHelper) stopOperator() {
oh.t.Errorf("unable to retrieve operator deployment: %v", err)
}

deployment.Spec.Replicas = akov2toptr.MakePtr(int32(0))
deployment.Spec.Replicas = pointer.Get(int32(0))

err = oh.k8sClient.Update(context.Background(), &deployment, &client.UpdateOptions{})
if err != nil {
Expand Down

0 comments on commit 070e846

Please sign in to comment.