2016-06-22 20:21:11 -05:00
|
|
|
package aws
|
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
2016-07-20 13:53:37 -05:00
|
|
|
"github.com/hashicorp/terraform/helper/acctest"
|
2016-06-22 20:21:11 -05:00
|
|
|
"github.com/hashicorp/terraform/helper/resource"
|
|
|
|
)
|
|
|
|
|
2016-07-20 13:53:37 -05:00
|
|
|
func TestAccAWSRDSCluster_importBasic(t *testing.T) {
|
|
|
|
resourceName := "aws_rds_cluster.default"
|
|
|
|
ri := acctest.RandInt()
|
2016-06-22 20:21:11 -05:00
|
|
|
|
|
|
|
resource.Test(t, resource.TestCase{
|
|
|
|
PreCheck: func() { testAccPreCheck(t) },
|
|
|
|
Providers: testAccProviders,
|
2016-07-20 13:53:37 -05:00
|
|
|
CheckDestroy: testAccCheckAWSClusterDestroy,
|
2016-06-22 20:21:11 -05:00
|
|
|
Steps: []resource.TestStep{
|
|
|
|
resource.TestStep{
|
2016-07-20 13:53:37 -05:00
|
|
|
Config: testAccAWSClusterConfig(ri),
|
2016-06-22 20:21:11 -05:00
|
|
|
},
|
|
|
|
|
|
|
|
resource.TestStep{
|
|
|
|
ResourceName: resourceName,
|
|
|
|
ImportState: true,
|
|
|
|
ImportStateVerify: true,
|
|
|
|
ImportStateVerifyIgnore: []string{
|
2016-07-20 13:53:37 -05:00
|
|
|
"master_password", "skip_final_snapshot"},
|
2016-06-22 20:21:11 -05:00
|
|
|
},
|
|
|
|
},
|
|
|
|
})
|
|
|
|
}
|