Skip to content

Commit

Permalink
Merge pull request #15986 from hashicorp/t-gov-hardendpoint-wafregional
Browse files Browse the repository at this point in the history
tests/provider: Fix hardcoded endpoint ID (wafregional)
  • Loading branch information
YakDriver authored Nov 3, 2020
2 parents 9834fca + 520dcea commit ad62ebe
Show file tree
Hide file tree
Showing 17 changed files with 82 additions and 76 deletions.
3 changes: 2 additions & 1 deletion aws/data_source_aws_wafregional_ipset_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"regexp"
"testing"

"github.com/aws/aws-sdk-go/service/wafregional"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
)
Expand All @@ -15,7 +16,7 @@ func TestAccDataSourceAwsWafRegionalIPSet_basic(t *testing.T) {
datasourceName := "data.aws_wafregional_ipset.ipset"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
Steps: []resource.TestStep{
{
Expand Down
3 changes: 2 additions & 1 deletion aws/data_source_aws_wafregional_rate_based_rule_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"regexp"
"testing"

"github.com/aws/aws-sdk-go/service/wafregional"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
)
Expand All @@ -15,7 +16,7 @@ func TestAccDataSourceAwsWafRegionalRateBasedRule_basic(t *testing.T) {
datasourceName := "data.aws_wafregional_rate_based_rule.wafrule"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
Steps: []resource.TestStep{
{
Expand Down
3 changes: 2 additions & 1 deletion aws/data_source_aws_wafregional_rule_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"regexp"
"testing"

"github.com/aws/aws-sdk-go/service/wafregional"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
)
Expand All @@ -15,7 +16,7 @@ func TestAccDataSourceAwsWafRegionalRule_basic(t *testing.T) {
datasourceName := "data.aws_wafregional_rule.wafrule"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
Steps: []resource.TestStep{
{
Expand Down
3 changes: 2 additions & 1 deletion aws/data_source_aws_wafregional_web_acl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"regexp"
"testing"

"github.com/aws/aws-sdk-go/service/wafregional"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
)
Expand All @@ -15,7 +16,7 @@ func TestAccDataSourceAwsWafRegionalWebAcl_basic(t *testing.T) {
datasourceName := "data.aws_wafregional_web_acl.web_acl"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
Steps: []resource.TestStep{
{
Expand Down
11 changes: 6 additions & 5 deletions aws/resource_aws_wafregional_byte_match_set_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (

"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/service/waf"
"github.com/aws/aws-sdk-go/service/wafregional"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/v2/terraform"
Expand All @@ -18,7 +19,7 @@ func TestAccAWSWafRegionalByteMatchSet_basic(t *testing.T) {
resourceName := "aws_wafregional_byte_match_set.byte_set"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalByteMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -64,7 +65,7 @@ func TestAccAWSWafRegionalByteMatchSet_changeNameForceNew(t *testing.T) {
resourceName := "aws_wafregional_byte_match_set.byte_set"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalByteMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -135,7 +136,7 @@ func TestAccAWSWafRegionalByteMatchSet_changeByteMatchTuples(t *testing.T) {
resourceName := "aws_wafregional_byte_match_set.byte_set"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalByteMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -204,7 +205,7 @@ func TestAccAWSWafRegionalByteMatchSet_noByteMatchTuples(t *testing.T) {
resourceName := "aws_wafregional_byte_match_set.byte_match_set"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalByteMatchSetDestroy,
Steps: []resource.TestStep{
Expand All @@ -231,7 +232,7 @@ func TestAccAWSWafRegionalByteMatchSet_disappears(t *testing.T) {
resourceName := "aws_wafregional_byte_match_set.byte_set"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalByteMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down
11 changes: 6 additions & 5 deletions aws/resource_aws_wafregional_geo_match_set_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (

"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/service/waf"
"github.com/aws/aws-sdk-go/service/wafregional"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/v2/terraform"
Expand All @@ -18,7 +19,7 @@ func TestAccAWSWafRegionalGeoMatchSet_basic(t *testing.T) {
geoMatchSet := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalGeoMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -56,7 +57,7 @@ func TestAccAWSWafRegionalGeoMatchSet_changeNameForceNew(t *testing.T) {
geoMatchSetNewName := fmt.Sprintf("geoMatchSetNewName-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalGeoMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -96,7 +97,7 @@ func TestAccAWSWafRegionalGeoMatchSet_disappears(t *testing.T) {
geoMatchSet := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalGeoMatchSetDestroy,
Steps: []resource.TestStep{
Expand All @@ -118,7 +119,7 @@ func TestAccAWSWafRegionalGeoMatchSet_changeConstraints(t *testing.T) {
setName := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalGeoMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -173,7 +174,7 @@ func TestAccAWSWafRegionalGeoMatchSet_noConstraints(t *testing.T) {
setName := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalGeoMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down
12 changes: 6 additions & 6 deletions aws/resource_aws_wafregional_ipset_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func TestAccAWSWafRegionalIPSet_basic(t *testing.T) {
ipsetName := fmt.Sprintf("ip-set-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalIPSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -54,7 +54,7 @@ func TestAccAWSWafRegionalIPSet_disappears(t *testing.T) {
var v waf.IPSet
ipsetName := fmt.Sprintf("ip-set-%s", acctest.RandString(5))
resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalIPSetDestroy,
Steps: []resource.TestStep{
Expand All @@ -77,7 +77,7 @@ func TestAccAWSWafRegionalIPSet_changeNameForceNew(t *testing.T) {
ipsetNewName := fmt.Sprintf("ip-set-new-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalIPSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -118,7 +118,7 @@ func TestAccAWSWafRegionalIPSet_changeDescriptors(t *testing.T) {
ipsetName := fmt.Sprintf("ip-set-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalIPSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -180,7 +180,7 @@ func TestAccAWSWafRegionalIPSet_IpSetDescriptors_1000UpdateLimit(t *testing.T) {
}

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalIPSetDestroy,
Steps: []resource.TestStep{
Expand All @@ -206,7 +206,7 @@ func TestAccAWSWafRegionalIPSet_noDescriptors(t *testing.T) {
ipsetName := fmt.Sprintf("ip-set-%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalIPSetDestroy,
Steps: []resource.TestStep{
Expand Down
14 changes: 7 additions & 7 deletions aws/resource_aws_wafregional_rate_based_rule_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ func TestAccAWSWafRegionalRateBasedRule_basic(t *testing.T) {
resourceName := "aws_wafregional_rate_based_rule.wafrule"
wafRuleName := fmt.Sprintf("wafrule%s", acctest.RandString(5))
resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -151,7 +151,7 @@ func TestAccAWSWafRegionalRateBasedRule_tags(t *testing.T) {
resourceName := "aws_wafregional_rate_based_rule.wafrule"
wafRuleName := fmt.Sprintf("wafrule%s", acctest.RandString(5))
resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -196,7 +196,7 @@ func TestAccAWSWafRegionalRateBasedRule_changeNameForceNew(t *testing.T) {
wafRuleNewName := fmt.Sprintf("wafrulenew%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -233,7 +233,7 @@ func TestAccAWSWafRegionalRateBasedRule_disappears(t *testing.T) {
resourceName := "aws_wafregional_rate_based_rule.wafrule"
wafRuleName := fmt.Sprintf("wafrule%s", acctest.RandString(5))
resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand All @@ -258,7 +258,7 @@ func TestAccAWSWafRegionalRateBasedRule_changePredicates(t *testing.T) {
ruleName := fmt.Sprintf("wafrule%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -305,7 +305,7 @@ func TestAccAWSWafRegionalRateBasedRule_changeRateLimit(t *testing.T) {
rateLimitAfter := "2001"

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -340,7 +340,7 @@ func TestAccAWSWafRegionalRateBasedRule_noPredicates(t *testing.T) {
ruleName := fmt.Sprintf("wafrule%s", acctest.RandString(5))

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRateBasedRuleDestroy,
Steps: []resource.TestStep{
Expand Down
8 changes: 4 additions & 4 deletions aws/resource_aws_wafregional_regex_match_set_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ func testAccAWSWafRegionalRegexMatchSet_basic(t *testing.T) {
}

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -159,7 +159,7 @@ func testAccAWSWafRegionalRegexMatchSet_changePatterns(t *testing.T) {
patternSetName := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -210,7 +210,7 @@ func testAccAWSWafRegionalRegexMatchSet_noPatterns(t *testing.T) {
matchSetName := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -238,7 +238,7 @@ func testAccAWSWafRegionalRegexMatchSet_disappears(t *testing.T) {
patternSetName := fmt.Sprintf("tfacc-%s", acctest.RandString(5))

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexMatchSetDestroy,
Steps: []resource.TestStep{
Expand Down
8 changes: 4 additions & 4 deletions aws/resource_aws_wafregional_regex_pattern_set_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func testAccAWSWafRegionalRegexPatternSet_basic(t *testing.T) {
resourceName := "aws_wafregional_regex_pattern_set.test"

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexPatternSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -66,7 +66,7 @@ func testAccAWSWafRegionalRegexPatternSet_changePatterns(t *testing.T) {
resourceName := "aws_wafregional_regex_pattern_set.test"

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexPatternSetDestroy,
Steps: []resource.TestStep{
Expand Down Expand Up @@ -106,7 +106,7 @@ func testAccAWSWafRegionalRegexPatternSet_noPatterns(t *testing.T) {
resourceName := "aws_wafregional_regex_pattern_set.test"

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexPatternSetDestroy,
Steps: []resource.TestStep{
Expand All @@ -133,7 +133,7 @@ func testAccAWSWafRegionalRegexPatternSet_disappears(t *testing.T) {
resourceName := "aws_wafregional_regex_pattern_set.test"

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck("waf-regional", t) },
PreCheck: func() { testAccPreCheck(t); testAccPartitionHasServicePreCheck(wafregional.EndpointsID, t) },
Providers: testAccProviders,
CheckDestroy: testAccCheckAWSWafRegionalRegexPatternSetDestroy,
Steps: []resource.TestStep{
Expand Down
Loading

0 comments on commit ad62ebe

Please sign in to comment.