Skip to content

Commit

Permalink
test: Skip in ci since it is slow and use new GetClusterInfo api
Browse files Browse the repository at this point in the history
  • Loading branch information
EspenAlbert committed Jul 11, 2024
1 parent ab532c2 commit ea473c5
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ import (
"github.com/hashicorp/terraform-plugin-testing/helper/resource"
"github.com/hashicorp/terraform-plugin-testing/terraform"
"github.com/mongodb/terraform-provider-mongodbatlas/internal/testutil/acc"
"go.mongodb.org/atlas-sdk/v20240530002/admin"
)

func TestAccPrivateEndpointRegionalMode_basic(t *testing.T) {
resource.ParallelTest(t, *basicTestCase(t))
}

func TestAccPrivateEndpointRegionalMode_conn(t *testing.T) {
acc.SkipTestForCI(t) // slow test ~90min vs ~15min of the 2nd slowest test in the network group
var (
endpointResourceSuffix = "atlasple"
resourceSuffix = "atlasrm"
Expand All @@ -29,9 +29,9 @@ func TestAccPrivateEndpointRegionalMode_conn(t *testing.T) {
region = os.Getenv("AWS_REGION_LOWERCASE")
privatelinkEndpointServiceResourceName = fmt.Sprintf("mongodbatlas_privatelink_endpoint_service.%s", endpointResourceSuffix)
clusterDependsOn = fmt.Sprintf("%s, %s", resourceName, privatelinkEndpointServiceResourceName)
spec1 = acc.ReplicationSpec(&acc.ReplicationSpecRequest{Region: os.Getenv("AWS_REGION_UPPERCASE"), ProviderName: providerName, ZoneName: "Zone 1"})
spec2 = acc.ReplicationSpec(&acc.ReplicationSpecRequest{Region: "US_WEST_2", ProviderName: providerName, ZoneName: "Zone 2"})
clusterInfo = acc.GetClusterInfo(t, &acc.ClusterRequest{Geosharded: true, DiskSizeGb: 80, ResourceDependencyName: clusterDependsOn, ReplicationSpecs: []admin.ReplicationSpec{spec1, spec2}})
spec1 = acc.ReplicationSpecRequest{Region: os.Getenv("AWS_REGION_UPPERCASE"), ProviderName: providerName, ZoneName: "Zone 1"}
spec2 = acc.ReplicationSpecRequest{Region: "US_WEST_2", ProviderName: providerName, ZoneName: "Zone 2"}
clusterInfo = acc.GetClusterInfo(t, &acc.ClusterRequest{Geosharded: true, DiskSizeGb: 80, ResourceDependencyName: clusterDependsOn, ReplicationSpecs: []acc.ReplicationSpecRequest{spec1, spec2}})
clusterName = clusterInfo.ClusterName
projectID = clusterInfo.ProjectID
clusterResourceName = clusterInfo.ClusterResourceName
Expand Down

0 comments on commit ea473c5

Please sign in to comment.