Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup leftover v1 references in merged aws-sdk-go-v2 migrations #38911

Merged
merged 60 commits into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
2f38402
feat: migrate provider acc tests from endpoints and v2 aws package
DanielRieske Aug 17, 2024
5eb6275
feat: migrated endpoints references with `acmpa`
DanielRieske Aug 17, 2024
f029c8f
feat: appflow flow migrate arn to `v2`
DanielRieske Aug 17, 2024
4c9ef77
feat: applicationinsights application migrate arn to v2
DanielRieske Aug 17, 2024
979fe70
feat: apprunner hosted_zone_id migrate endpoints to names
DanielRieske Aug 17, 2024
e7b2769
feat: backup region_settings migrate `PreCheckPartitionHasService` wi…
DanielRieske Aug 17, 2024
29929b3
feat: backup vault migrate arn to v2
DanielRieske Aug 17, 2024
0ce5890
feat: `backup` slack_channel_configuration migrate arn to v2
DanielRieske Aug 17, 2024
8ba7ecc
feat: `cloudcontrol` resource migrate endpoint id to names reference
DanielRieske Aug 17, 2024
89646a8
feat: `cloudfront` distribution migrate endpoint id to names reference
DanielRieske Aug 17, 2024
4e579c1
feat: migrate `TestAccCloudFrontOriginAccessIdentitiesDataSource_all`…
DanielRieske Aug 17, 2024
36a18f9
feat: `cloudtrail` migrate endpoints to names and upgrade arn to sdkv2
DanielRieske Aug 17, 2024
e3e18f1
feat: migrate `TestAccCognitoIDPUserGroupsDataSource_basic` and `Test…
DanielRieske Aug 17, 2024
675fbc9
feat: migrate `cur` d/report_definition to use the aws v2 package
DanielRieske Aug 17, 2024
52429fd
feat: migrate `datasync` r/location_efs and r/location_fsx_* to use e…
DanielRieske Aug 17, 2024
d9af9c2
feat: migrate `devicefarm` endpoint references to names package and u…
DanielRieske Aug 17, 2024
8d68a1a
feat: migrate `directconnect` arn references to v2 and several endpoi…
DanielRieske Aug 17, 2024
83e4fa2
docs: update aws-sdk-go-v2 docs reference
DanielRieske Aug 17, 2024
26195aa
feat: migrate `dynamodb` d/table_item endpoints reference to names pa…
DanielRieske Aug 17, 2024
bb9e524
feat: migrate `ec2` r/vpc_default_subnet endpoints reference to names…
DanielRieske Aug 17, 2024
efd49f0
feat: migrate `ecs` r/task_definition endpoint references to names pa…
DanielRieske Aug 17, 2024
f601fe3
feat: migrate `eks` `TestAccEKSAddonDataSource_configurationValues` t…
DanielRieske Aug 17, 2024
d3c2fc7
fix: `TestAccEKSAddonDataSource_configurationValues` addon version to…
DanielRieske Aug 17, 2024
f56a585
feat: migrate `elasticache` d/subnet_group preCheck to use names pack…
DanielRieske Aug 17, 2024
e4679cb
feat: migrate `elasticbeanstalk` d/hosted_zone to use names package i…
DanielRieske Aug 17, 2024
bc08084
feat: migrate `elbv2` d/load_balancers and d/target_group use `aws-sd…
DanielRieske Aug 17, 2024
c97b225
feat: migrate `events` `validate` file to use arn v2 and names instea…
DanielRieske Aug 17, 2024
35aa15d
feat: migrate `evidently` wait functions to use evidently v2 types
DanielRieske Aug 17, 2024
14c15d0
feat: migrate `fsx` `TestAccFSxDataRepositoryAssociation_*` and `Test…
DanielRieske Aug 17, 2024
84b6e52
feat: migrate `guardduty` r/malware_protection_plan to use `aws-sdk-g…
DanielRieske Aug 17, 2024
a7a33cb
feat: migrate `kafkaconnect` change several test files using endpoint…
DanielRieske Aug 17, 2024
d6ae295
feat: migrate `verify` validate arn package to v2 and added `CloudCon…
DanielRieske Aug 17, 2024
e3c1b90
chore: revert comment deletion
DanielRieske Aug 17, 2024
027bcfb
feat: migrate `keyspaces` r/keyspace tests `preCheck` to use names pa…
DanielRieske Aug 18, 2024
bc1d978
feat: migrate `kms` d/alias to use aws package v2 and use arn v2 for …
DanielRieske Aug 18, 2024
3713ba6
feat: migrate `lakeformation` d/permissions to use names package for …
DanielRieske Aug 18, 2024
635b136
feat: migrate `location` r/tracker upgrade `aws-sdk-go` to v2
DanielRieske Aug 18, 2024
be67804
feat: migrate `memorydb` r/subnet_group tests to use names package fo…
DanielRieske Aug 18, 2024
f5d4468
feat: migrate `oam` d/links and d/sinks to use `aws-sdk-go` v2 version
DanielRieske Aug 18, 2024
7b782f7
feat: migrate `paymentcryptography` r/key_alias to use `aws-sdk-go` v…
DanielRieske Aug 18, 2024
3e39439
feat: migrate `pricing` d/product to use names package in `preCheckRe…
DanielRieske Aug 18, 2024
db6607d
feat: migrate `rbin` r/rule upgrade arn package to v2
DanielRieske Aug 18, 2024
92cefc9
feat: migrate `rds` - newBlueGreenOrchestrator to use `aws-sdk-go` v2…
DanielRieske Aug 18, 2024
e22c0d7
feat: migrate `redshift` d/service_account to use arn v2 and use name…
DanielRieske Aug 18, 2024
9c23c02
feat: migrate `rolesanywhere` r/profile and r/trust_anchor to use `aw…
DanielRieske Aug 18, 2024
824938d
feat: migrate `route53` d/delegation_set to use arnv2 and r/health_ch…
DanielRieske Aug 18, 2024
341b7bd
feat: migrate `route53` d/traffic_policy_document to use `reflect.Dee…
DanielRieske Aug 18, 2024
56c47be
feat: migrate `route53resolver` d/query_log_config to use names packa…
DanielRieske Aug 18, 2024
ad78819
feat: migrate `s3` `TestAccS3Bucket_Basic_acceleration` to use names …
DanielRieske Aug 18, 2024
ce17122
feat: migrate `securityhub` r/account and r/finding_aggregator tests …
DanielRieske Aug 18, 2024
7cbedac
feat: migrate `sesv2` r/configuration, r/contact_list, r/email_identi…
DanielRieske Aug 18, 2024
8805649
feat: migrate `shield` r/protection test to use names package instead…
DanielRieske Aug 18, 2024
a29c9fe
feat: migrate `ssmcontacts` r/rotation to use `aws-sdk-go` v2
DanielRieske Aug 18, 2024
4be654a
feat: migrate `ssmincidents` r/replication_set to use arn v2
DanielRieske Aug 18, 2024
4617f15
chore: `ssmincidents` `TestAccSSMIncidents_serial` change key in map …
DanielRieske Aug 18, 2024
f8f40d6
feat: `storagegateway` remove unused `CustomizeConn` declaration for …
DanielRieske Aug 18, 2024
1a9491f
feat: migrate `transcribe` to use arn v2 package
DanielRieske Aug 18, 2024
c6496f4
feat: migrate `vpclattice` d/service and d/service_network arn packag…
DanielRieske Aug 18, 2024
66ec671
feat: migrate `waf` `TestAccWAFWebACL_logging` test to use names pack…
DanielRieske Aug 18, 2024
c5f451d
feat: migrate `wafv2` `flattenAssociationConfig` used in r/web_acl to…
DanielRieske Aug 18, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 16 additions & 17 deletions internal/provider/provider_acc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,9 @@ import (
"strings"
"testing"

"github.com/aws/aws-sdk-go-v2/aws"
awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
sts_sdkv2 "github.com/aws/aws-sdk-go-v2/service/sts"
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/endpoints"
"github.com/aws/smithy-go/middleware"
"github.com/hashicorp/terraform-plugin-go/tfprotov5"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
Expand Down Expand Up @@ -518,10 +517,10 @@ func TestAccProvider_Region_c2s(t *testing.T) {
CheckDestroy: nil,
Steps: []resource.TestStep{
{
Config: testAccProviderConfig_region(endpoints.UsIsoEast1RegionID),
Config: testAccProviderConfig_region(names.USISOEast1RegionID),
Check: resource.ComposeTestCheckFunc(
testAccCheckDNSSuffix(ctx, t, &provider, "c2s.ic.gov"),
testAccCheckPartition(ctx, t, &provider, endpoints.AwsIsoPartitionID),
testAccCheckPartition(ctx, t, &provider, names.ISOPartitionID),
testAccCheckReverseDNSPrefix(ctx, t, &provider, "gov.ic.c2s"),
),
PlanOnly: true,
Expand All @@ -541,10 +540,10 @@ func TestAccProvider_Region_china(t *testing.T) {
CheckDestroy: nil,
Steps: []resource.TestStep{
{
Config: testAccProviderConfig_region(endpoints.CnNorthwest1RegionID),
Config: testAccProviderConfig_region(names.CNNorthwest1RegionID),
Check: resource.ComposeTestCheckFunc(
testAccCheckDNSSuffix(ctx, t, &provider, "amazonaws.com.cn"),
testAccCheckPartition(ctx, t, &provider, endpoints.AwsCnPartitionID),
testAccCheckPartition(ctx, t, &provider, names.ChinaPartitionID),
testAccCheckReverseDNSPrefix(ctx, t, &provider, "cn.com.amazonaws"),
),
PlanOnly: true,
Expand All @@ -564,10 +563,10 @@ func TestAccProvider_Region_commercial(t *testing.T) {
CheckDestroy: nil,
Steps: []resource.TestStep{
{
Config: testAccProviderConfig_region(endpoints.UsWest2RegionID),
Config: testAccProviderConfig_region(names.USWest2RegionID),
Check: resource.ComposeTestCheckFunc(
testAccCheckDNSSuffix(ctx, t, &provider, "amazonaws.com"),
testAccCheckPartition(ctx, t, &provider, endpoints.AwsPartitionID),
testAccCheckPartition(ctx, t, &provider, names.StandardPartitionID),
testAccCheckReverseDNSPrefix(ctx, t, &provider, "com.amazonaws"),
),
PlanOnly: true,
Expand All @@ -587,10 +586,10 @@ func TestAccProvider_Region_govCloud(t *testing.T) {
CheckDestroy: nil,
Steps: []resource.TestStep{
{
Config: testAccProviderConfig_region(endpoints.UsGovWest1RegionID),
Config: testAccProviderConfig_region(names.USGovWest1RegionID),
Check: resource.ComposeTestCheckFunc(
testAccCheckDNSSuffix(ctx, t, &provider, "amazonaws.com"),
testAccCheckPartition(ctx, t, &provider, endpoints.AwsUsGovPartitionID),
testAccCheckPartition(ctx, t, &provider, names.USGovCloudPartitionID),
testAccCheckReverseDNSPrefix(ctx, t, &provider, "com.amazonaws"),
),
PlanOnly: true,
Expand All @@ -610,10 +609,10 @@ func TestAccProvider_Region_sc2s(t *testing.T) {
CheckDestroy: nil,
Steps: []resource.TestStep{
{
Config: testAccProviderConfig_region(endpoints.UsIsobEast1RegionID),
Config: testAccProviderConfig_region(names.USISOBEast1RegionID),
Check: resource.ComposeTestCheckFunc(
testAccCheckDNSSuffix(ctx, t, &provider, "sc2s.sgov.gov"),
testAccCheckPartition(ctx, t, &provider, endpoints.AwsIsoBPartitionID),
testAccCheckPartition(ctx, t, &provider, names.ISOBPartitionID),
testAccCheckReverseDNSPrefix(ctx, t, &provider, "gov.sgov.sc2s"),
),
PlanOnly: true,
Expand All @@ -633,10 +632,10 @@ func TestAccProvider_Region_stsRegion(t *testing.T) {
CheckDestroy: nil,
Steps: []resource.TestStep{
{
Config: testAccProviderConfig_stsRegion(endpoints.UsEast1RegionID, endpoints.UsWest2RegionID),
Config: testAccProviderConfig_stsRegion(names.USEast1RegionID, names.USWest2RegionID),
Check: resource.ComposeTestCheckFunc(
testAccCheckRegion(ctx, t, &provider, endpoints.UsEast1RegionID),
testAccCheckSTSRegion(ctx, t, &provider, endpoints.UsWest2RegionID),
testAccCheckRegion(ctx, t, &provider, names.USEast1RegionID),
testAccCheckSTSRegion(ctx, t, &provider, names.USWest2RegionID),
),
PlanOnly: true,
},
Expand Down Expand Up @@ -951,7 +950,7 @@ func testAccCheckProviderDefaultTags_Tags(ctx context.Context, t *testing.T, p *
var found bool

for _, actualElement := range actualTags {
if aws.StringValue(actualElement.Value) == expectedElement {
if aws.ToString(actualElement.Value) == expectedElement {
found = true
break
}
Expand All @@ -966,7 +965,7 @@ func testAccCheckProviderDefaultTags_Tags(ctx context.Context, t *testing.T, p *
var found bool

for _, expectedElement := range expectedTags {
if aws.StringValue(actualElement.Value) == expectedElement {
if aws.ToString(actualElement.Value) == expectedElement {
found = true
break
}
Expand Down
48 changes: 23 additions & 25 deletions internal/service/acmpca/certificate_authority_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@ import (
"testing"

"github.com/YakDriver/regexache"
"github.com/aws/aws-sdk-go-v2/service/acmpca/types"
"github.com/aws/aws-sdk-go/aws/endpoints"
"github.com/aws/aws-sdk-go/service/acmpca"
awstypes "github.com/aws/aws-sdk-go-v2/service/acmpca/types"
sdkacctest "github.com/hashicorp/terraform-plugin-testing/helper/acctest"
"github.com/hashicorp/terraform-plugin-testing/helper/resource"
"github.com/hashicorp/terraform-plugin-testing/terraform"
Expand All @@ -26,7 +24,7 @@ var testAccCheckCertificateAuthorityExists = acctest.CheckACMPCACertificateAutho

func TestAccACMPCACertificateAuthority_basic(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand Down Expand Up @@ -74,7 +72,7 @@ func TestAccACMPCACertificateAuthority_basic(t *testing.T) {

func TestAccACMPCACertificateAuthority_disappears(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand All @@ -98,7 +96,7 @@ func TestAccACMPCACertificateAuthority_disappears(t *testing.T) {

func TestAccACMPCACertificateAuthority_enabledDeprecated(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand All @@ -109,24 +107,24 @@ func TestAccACMPCACertificateAuthority_enabledDeprecated(t *testing.T) {
CheckDestroy: testAccCheckCertificateAuthorityDestroy(ctx),
Steps: []resource.TestStep{
{
Config: testAccCertificateAuthorityConfig_enabled(commonName, acmpca.CertificateAuthorityTypeRoot, true),
Config: testAccCertificateAuthorityConfig_enabled(commonName, string(awstypes.CertificateAuthorityTypeRoot), true),
Check: resource.ComposeTestCheckFunc(
testAccCheckCertificateAuthorityExists(ctx, resourceName, &certificateAuthority),
resource.TestCheckResourceAttr(resourceName, names.AttrType, acmpca.CertificateAuthorityTypeRoot),
resource.TestCheckResourceAttr(resourceName, names.AttrType, string(awstypes.CertificateAuthorityTypeRoot)),
resource.TestCheckResourceAttr(resourceName, names.AttrEnabled, acctest.CtTrue),
acctest.CheckACMPCACertificateAuthorityActivateRootCA(ctx, &certificateAuthority),
),
},
{
Config: testAccCertificateAuthorityConfig_enabled(commonName, acmpca.CertificateAuthorityTypeRoot, true),
Config: testAccCertificateAuthorityConfig_enabled(commonName, string(awstypes.CertificateAuthorityTypeRoot), true),
Check: resource.ComposeTestCheckFunc(
testAccCheckCertificateAuthorityExists(ctx, resourceName, &certificateAuthority),
resource.TestCheckResourceAttr(resourceName, names.AttrType, acmpca.CertificateAuthorityTypeRoot),
resource.TestCheckResourceAttr(resourceName, names.AttrType, string(awstypes.CertificateAuthorityTypeRoot)),
resource.TestCheckResourceAttr(resourceName, names.AttrEnabled, acctest.CtTrue),
),
},
{
Config: testAccCertificateAuthorityConfig_enabled(commonName, acmpca.CertificateAuthorityTypeRoot, false),
Config: testAccCertificateAuthorityConfig_enabled(commonName, string(awstypes.CertificateAuthorityTypeRoot), false),
Check: resource.ComposeTestCheckFunc(
testAccCheckCertificateAuthorityExists(ctx, resourceName, &certificateAuthority),
resource.TestCheckResourceAttr(resourceName, names.AttrEnabled, acctest.CtFalse),
Expand All @@ -146,7 +144,7 @@ func TestAccACMPCACertificateAuthority_enabledDeprecated(t *testing.T) {

func TestAccACMPCACertificateAuthority_usageMode(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand All @@ -157,7 +155,7 @@ func TestAccACMPCACertificateAuthority_usageMode(t *testing.T) {
CheckDestroy: testAccCheckCertificateAuthorityDestroy(ctx),
Steps: []resource.TestStep{
{
Config: testAccCertificateAuthorityConfig_usageMode(commonName, acmpca.CertificateAuthorityTypeRoot, "SHORT_LIVED_CERTIFICATE"),
Config: testAccCertificateAuthorityConfig_usageMode(commonName, string(awstypes.CertificateAuthorityTypeRoot), "SHORT_LIVED_CERTIFICATE"),
Check: resource.ComposeTestCheckFunc(
testAccCheckCertificateAuthorityExists(ctx, resourceName, &certificateAuthority),
resource.TestCheckResourceAttr(resourceName, "usage_mode", "SHORT_LIVED_CERTIFICATE"),
Expand All @@ -177,22 +175,22 @@ func TestAccACMPCACertificateAuthority_usageMode(t *testing.T) {

func TestAccACMPCACertificateAuthority_keyStorageSecurityStandard(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

resource.ParallelTest(t, resource.TestCase{
PreCheck: func() {
acctest.PreCheck(ctx, t)
// See https://docs.aws.amazon.com/privateca/latest/userguide/data-protection.html#private-keys.
acctest.PreCheckRegion(t, endpoints.ApSouth2RegionID, endpoints.ApSoutheast3RegionID, endpoints.ApSoutheast4RegionID, endpoints.EuCentral2RegionID, endpoints.EuSouth2RegionID, endpoints.MeCentral1RegionID)
acctest.PreCheckRegion(t, names.APSouth2RegionID, names.APSoutheast3RegionID, names.APSoutheast4RegionID, names.EUCentral2RegionID, names.EUSouth2RegionID, names.MECentral1RegionID)
},
ErrorCheck: acctest.ErrorCheck(t, names.ACMPCAServiceID),
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories,
CheckDestroy: testAccCheckCertificateAuthorityDestroy(ctx),
Steps: []resource.TestStep{
{
Config: testAccCertificateAuthorityConfig_keyStorageSecurityStandard(commonName, acmpca.CertificateAuthorityTypeRoot, "FIPS_140_2_LEVEL_2_OR_HIGHER"),
Config: testAccCertificateAuthorityConfig_keyStorageSecurityStandard(commonName, string(awstypes.CertificateAuthorityTypeRoot), "FIPS_140_2_LEVEL_2_OR_HIGHER"),
Check: resource.ComposeTestCheckFunc(
testAccCheckCertificateAuthorityExists(ctx, resourceName, &certificateAuthority),
resource.TestCheckResourceAttr(resourceName, "key_storage_security_standard", "FIPS_140_2_LEVEL_2_OR_HIGHER"),
Expand All @@ -212,7 +210,7 @@ func TestAccACMPCACertificateAuthority_keyStorageSecurityStandard(t *testing.T)

func TestAccACMPCACertificateAuthority_deleteFromActiveState(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand All @@ -226,7 +224,7 @@ func TestAccACMPCACertificateAuthority_deleteFromActiveState(t *testing.T) {
Config: testAccCertificateAuthorityConfig_root(commonName),
Check: resource.ComposeAggregateTestCheckFunc(
testAccCheckCertificateAuthorityExists(ctx, resourceName, &certificateAuthority),
resource.TestCheckResourceAttr(resourceName, names.AttrType, acmpca.CertificateAuthorityTypeRoot),
resource.TestCheckResourceAttr(resourceName, names.AttrType, string(awstypes.CertificateAuthorityTypeRoot)),
resource.TestCheckResourceAttr(resourceName, names.AttrEnabled, acctest.CtTrue),
),
},
Expand All @@ -236,7 +234,7 @@ func TestAccACMPCACertificateAuthority_deleteFromActiveState(t *testing.T) {

func TestAccACMPCACertificateAuthority_RevocationConfiguration_empty(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand Down Expand Up @@ -284,7 +282,7 @@ func TestAccACMPCACertificateAuthority_RevocationConfiguration_empty(t *testing.

func TestAccACMPCACertificateAuthority_RevocationCrl_customCNAME(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
rName := sdkacctest.RandomWithPrefix(acctest.ResourcePrefix)
resourceName := "aws_acmpca_certificate_authority.test"
domain := acctest.RandomDomain()
Expand Down Expand Up @@ -375,7 +373,7 @@ func TestAccACMPCACertificateAuthority_RevocationCrl_customCNAME(t *testing.T) {

func TestAccACMPCACertificateAuthority_RevocationCrl_enabled(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
rName := sdkacctest.RandomWithPrefix(acctest.ResourcePrefix)
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()
Expand Down Expand Up @@ -447,7 +445,7 @@ func TestAccACMPCACertificateAuthority_RevocationCrl_enabled(t *testing.T) {

func TestAccACMPCACertificateAuthority_RevocationCrl_expirationInDays(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
rName := sdkacctest.RandomWithPrefix(acctest.ResourcePrefix)
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()
Expand Down Expand Up @@ -509,7 +507,7 @@ func TestAccACMPCACertificateAuthority_RevocationCrl_expirationInDays(t *testing

func TestAccACMPCACertificateAuthority_RevocationCrl_s3ObjectACL(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
rName := sdkacctest.RandomWithPrefix(acctest.ResourcePrefix)
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()
Expand Down Expand Up @@ -561,7 +559,7 @@ func TestAccACMPCACertificateAuthority_RevocationCrl_s3ObjectACL(t *testing.T) {

func TestAccACMPCACertificateAuthority_RevocationOcsp_enabled(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
commonName := acctest.RandomDomainName()

Expand Down Expand Up @@ -628,7 +626,7 @@ func TestAccACMPCACertificateAuthority_RevocationOcsp_enabled(t *testing.T) {

func TestAccACMPCACertificateAuthority_RevocationOcsp_customCNAME(t *testing.T) {
ctx := acctest.Context(t)
var certificateAuthority types.CertificateAuthority
var certificateAuthority awstypes.CertificateAuthority
resourceName := "aws_acmpca_certificate_authority.test"
domain := acctest.RandomDomain()
commonName := domain.String()
Expand Down
2 changes: 1 addition & 1 deletion internal/service/appflow/flow.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ import (

"github.com/YakDriver/regexache"
"github.com/aws/aws-sdk-go-v2/aws"
"github.com/aws/aws-sdk-go-v2/aws/arn"
"github.com/aws/aws-sdk-go-v2/service/appflow"
"github.com/aws/aws-sdk-go-v2/service/appflow/types"
"github.com/aws/aws-sdk-go/aws/arn"
"github.com/hashicorp/terraform-plugin-sdk/v2/diag"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/retry"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
Expand Down
2 changes: 1 addition & 1 deletion internal/service/applicationinsights/application.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ import (
"time"

"github.com/aws/aws-sdk-go-v2/aws"
"github.com/aws/aws-sdk-go-v2/aws/arn"
"github.com/aws/aws-sdk-go-v2/service/applicationinsights"
awstypes "github.com/aws/aws-sdk-go-v2/service/applicationinsights/types"
"github.com/aws/aws-sdk-go/aws/arn"
"github.com/hashicorp/terraform-plugin-sdk/v2/diag"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/retry"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
Expand Down
23 changes: 11 additions & 12 deletions internal/service/apprunner/hosted_zone_id_data_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import (
"context"
"fmt"

"github.com/aws/aws-sdk-go/aws/endpoints"
"github.com/hashicorp/terraform-plugin-framework/datasource"
"github.com/hashicorp/terraform-plugin-framework/datasource/schema"
"github.com/hashicorp/terraform-plugin-framework/types"
Expand All @@ -18,17 +17,17 @@ import (
// See https://docs.aws.amazon.com/general/latest/gr/apprunner.html

var hostedZoneIDPerRegionMap = map[string]string{
endpoints.UsEast2RegionID: "Z0224347AD7KVHMLOX31",
endpoints.UsEast1RegionID: "Z01915732ZBZKC8D32TPT",
endpoints.UsWest2RegionID: "Z02243383FTQ64HJ5772Q",
endpoints.ApSouth1RegionID: "Z00855883LBHKTIC4ODF2",
endpoints.ApSoutheast1RegionID: "Z09819469CZ3KQ8PWMCL",
endpoints.ApSoutheast2RegionID: "Z03657752RA8799S0TI5I",
endpoints.ApNortheast1RegionID: "Z08491812XW6IPYLR6CCA",
endpoints.EuCentral1RegionID: "Z0334911C2FDI2Q9M4FZ",
endpoints.EuWest1RegionID: "Z087551914Z2PCAU0QHMW",
endpoints.EuWest2RegionID: "Z098228427VC6B3IX76ON",
endpoints.EuWest3RegionID: "Z087117439MBKHYM69QS6",
names.USEast2RegionID: "Z0224347AD7KVHMLOX31",
names.USEast1RegionID: "Z01915732ZBZKC8D32TPT",
names.USWest2RegionID: "Z02243383FTQ64HJ5772Q",
names.APSouth1RegionID: "Z00855883LBHKTIC4ODF2",
names.APSoutheast1RegionID: "Z09819469CZ3KQ8PWMCL",
names.APSoutheast2RegionID: "Z03657752RA8799S0TI5I",
names.APNortheast1RegionID: "Z08491812XW6IPYLR6CCA",
names.EUCentral1RegionID: "Z0334911C2FDI2Q9M4FZ",
names.EUWest1RegionID: "Z087551914Z2PCAU0QHMW",
names.EUWest2RegionID: "Z098228427VC6B3IX76ON",
names.EUWest3RegionID: "Z087117439MBKHYM69QS6",
}

// @FrameworkDataSource("aws_apprunner_hosted_zone_id", name="Hosted Zone ID")
Expand Down
3 changes: 1 addition & 2 deletions internal/service/backup/region_settings_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"testing"

"github.com/aws/aws-sdk-go-v2/service/backup"
"github.com/aws/aws-sdk-go/service/fsx"
"github.com/hashicorp/terraform-plugin-testing/helper/resource"
"github.com/hashicorp/terraform-plugin-testing/terraform"
"github.com/hashicorp/terraform-provider-aws/internal/acctest"
Expand All @@ -24,7 +23,7 @@ func TestAccBackupRegionSettings_basic(t *testing.T) {
resource.ParallelTest(t, resource.TestCase{
PreCheck: func() {
acctest.PreCheck(ctx, t)
acctest.PreCheckPartitionHasService(t, fsx.EndpointsID)
acctest.PreCheckPartitionHasService(t, names.FSxEndpointID)
testAccPreCheck(ctx, t)
},
ErrorCheck: acctest.ErrorCheck(t, names.BackupServiceID),
Expand Down
2 changes: 1 addition & 1 deletion internal/service/backup/vault_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import (
"time"

"github.com/aws/aws-sdk-go-v2/aws"
"github.com/aws/aws-sdk-go-v2/aws/arn"
"github.com/aws/aws-sdk-go-v2/service/backup"
"github.com/aws/aws-sdk-go/aws/arn"
sdkacctest "github.com/hashicorp/terraform-plugin-testing/helper/acctest"
"github.com/hashicorp/terraform-plugin-testing/helper/resource"
"github.com/hashicorp/terraform-plugin-testing/terraform"
Expand Down
2 changes: 1 addition & 1 deletion internal/service/chatbot/slack_channel_configuration.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ import (
"time"

"github.com/aws/aws-sdk-go-v2/aws"
"github.com/aws/aws-sdk-go-v2/aws/arn"
"github.com/aws/aws-sdk-go-v2/service/chatbot"
awstypes "github.com/aws/aws-sdk-go-v2/service/chatbot/types"
"github.com/aws/aws-sdk-go/aws/arn"
"github.com/hashicorp/terraform-plugin-framework-timeouts/resource/timeouts"
"github.com/hashicorp/terraform-plugin-framework/path"
"github.com/hashicorp/terraform-plugin-framework/resource"
Expand Down
Loading
Loading