diff --git a/internal/service/memorydb/user_data_source_test.go b/internal/service/memorydb/user_data_source_test.go index e3b2a5f4873..b11a9d4de6b 100644 --- a/internal/service/memorydb/user_data_source_test.go +++ b/internal/service/memorydb/user_data_source_test.go @@ -41,7 +41,7 @@ func TestAccMemoryDBUserDataSource_basic(t *testing.T) { }) } -func TestAccMemoryDBUserDataSource_iam(t *testing.T) { +func TestAccMemoryDBUserDataSource_authenticationModeIAM(t *testing.T) { ctx := acctest.Context(t) rName := "tf-test-" + sdkacctest.RandString(8) resourceName := "aws_memorydb_user.test" @@ -53,15 +53,13 @@ func TestAccMemoryDBUserDataSource_iam(t *testing.T) { ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories, Steps: []resource.TestStep{ { - Config: testAccUserDataSourceConfig_iam(rName), + Config: testAccUserDataSourceConfig_authenticationModeIAM(rName), Check: resource.ComposeAggregateTestCheckFunc( resource.TestCheckResourceAttrPair(dataSourceName, "access_string", resourceName, "access_string"), resource.TestCheckResourceAttrPair(dataSourceName, "arn", resourceName, "arn"), resource.TestCheckResourceAttrPair(dataSourceName, "authentication_mode.0.type", resourceName, "authentication_mode.0.type"), resource.TestCheckResourceAttrPair(dataSourceName, "authentication_mode.0.password_count", resourceName, "authentication_mode.0.password_count"), resource.TestCheckResourceAttrPair(dataSourceName, "minimum_engine_version", resourceName, "minimum_engine_version"), - resource.TestCheckResourceAttr(dataSourceName, "tags.%", "1"), - resource.TestCheckResourceAttrPair(dataSourceName, "tags.Test", resourceName, "tags.Test"), resource.TestCheckResourceAttrPair(dataSourceName, "user_name", resourceName, "user_name"), ), }, @@ -91,7 +89,7 @@ data "aws_memorydb_user" "test" { `, rName) } -func testAccUserDataSourceConfig_iam(rName string) string { +func testAccUserDataSourceConfig_authenticationModeIAM(rName string) string { return fmt.Sprintf(` resource "aws_memorydb_user" "test" { access_string = "on ~* &* +@all" @@ -100,10 +98,6 @@ resource "aws_memorydb_user" "test" { authentication_mode { type = "iam" } - - tags = { - Test = "test" - } } data "aws_memorydb_user" "test" { diff --git a/internal/service/memorydb/user_test.go b/internal/service/memorydb/user_test.go index 01f5d36f9fc..7dac2652cf3 100644 --- a/internal/service/memorydb/user_test.go +++ b/internal/service/memorydb/user_test.go @@ -55,7 +55,7 @@ func TestAccMemoryDBUser_basic(t *testing.T) { }) } -func TestAccMemoryDBUser_iam_auth_mode(t *testing.T) { +func TestAccMemoryDBUser_authenticationModeIAM(t *testing.T) { ctx := acctest.Context(t) rName := "tf-test-" + sdkacctest.RandString(8) resourceName := "aws_memorydb_user.test" @@ -67,7 +67,7 @@ func TestAccMemoryDBUser_iam_auth_mode(t *testing.T) { CheckDestroy: testAccCheckUserDestroy(ctx), Steps: []resource.TestStep{ { - Config: testAccUserConfigWithIAMAuthMode_basic(rName), + Config: testAccUserConfig_authenticationModeIAM(rName), Check: resource.ComposeTestCheckFunc( testAccCheckUserExists(ctx, resourceName), resource.TestCheckResourceAttr(resourceName, "access_string", "on ~* &* +@all"), @@ -76,8 +76,6 @@ func TestAccMemoryDBUser_iam_auth_mode(t *testing.T) { resource.TestCheckResourceAttr(resourceName, "authentication_mode.0.password_count", "0"), resource.TestCheckResourceAttrSet(resourceName, "minimum_engine_version"), resource.TestCheckResourceAttr(resourceName, "user_name", rName), - resource.TestCheckResourceAttr(resourceName, "tags.%", "1"), - resource.TestCheckResourceAttr(resourceName, "tags.Test", "test"), ), }, { @@ -313,7 +311,7 @@ resource "aws_memorydb_user" "test" { `, rName) } -func testAccUserConfigWithIAMAuthMode_basic(rName string) string { +func testAccUserConfig_authenticationModeIAM(rName string) string { return fmt.Sprintf(` resource "aws_memorydb_user" "test" { access_string = "on ~* &* +@all" @@ -322,10 +320,6 @@ resource "aws_memorydb_user" "test" { authentication_mode { type = "iam" } - - tags = { - Test = "test" - } } `, rName) }