2016-06-23 03:33:29 +02:00
|
|
|
package aws
|
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
2016-11-25 16:37:19 +01:00
|
|
|
"github.com/hashicorp/terraform/helper/acctest"
|
2016-06-23 03:33:29 +02:00
|
|
|
"github.com/hashicorp/terraform/helper/resource"
|
|
|
|
)
|
|
|
|
|
|
|
|
func TestAccAWSRedshiftSubnetGroup_importBasic(t *testing.T) {
|
|
|
|
resourceName := "aws_redshift_subnet_group.foo"
|
2016-11-25 16:37:19 +01:00
|
|
|
rInt := acctest.RandInt()
|
2016-06-23 03:33:29 +02:00
|
|
|
|
|
|
|
resource.Test(t, resource.TestCase{
|
|
|
|
PreCheck: func() { testAccPreCheck(t) },
|
|
|
|
Providers: testAccProviders,
|
|
|
|
CheckDestroy: testAccCheckRedshiftSubnetGroupDestroy,
|
|
|
|
Steps: []resource.TestStep{
|
|
|
|
resource.TestStep{
|
2016-11-25 16:37:19 +01:00
|
|
|
Config: testAccRedshiftSubnetGroupConfig(rInt),
|
2016-06-23 03:33:29 +02:00
|
|
|
},
|
|
|
|
|
|
|
|
resource.TestStep{
|
|
|
|
ResourceName: resourceName,
|
|
|
|
ImportState: true,
|
|
|
|
ImportStateVerify: true,
|
|
|
|
ImportStateVerifyIgnore: []string{
|
|
|
|
"description"},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
})
|
|
|
|
}
|