Skip to content

Commit

Permalink
tests/resource/workspaces_directory: Fix hardcoded region
Browse files Browse the repository at this point in the history
  • Loading branch information
YakDriver committed Dec 7, 2020
1 parent 346cac9 commit 54ca703
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions aws/resource_aws_workspaces_directory_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"testing"

"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/endpoints"
"github.com/aws/aws-sdk-go/service/iam"
"github.com/aws/aws-sdk-go/service/workspaces"
multierror "github.com/hashicorp/go-multierror"
Expand Down Expand Up @@ -515,7 +516,7 @@ data "aws_availability_zones" "available" {
locals {
region_workspaces_az_ids = {
"us-east-1" = formatlist("use1-az%%d", [2, 4, 6])
%q = formatlist("use1-az%%d", [2, 4, 6])
}
workspaces_az_ids = lookup(local.region_workspaces_az_ids, data.aws_region.current.name, data.aws_availability_zones.available.zone_ids)
Expand Down Expand Up @@ -563,7 +564,7 @@ resource "aws_directory_service_directory" "main" {
Name = "tf-testacc-workspaces-directory-%[1]s"
}
}
`, rName)
`, rName, endpoints.UsEast1RegionID)
}

func testAccWorkspacesDirectoryConfig(rName string) string {
Expand Down

0 comments on commit 54ca703

Please sign in to comment.