2016-07-06 12:21:47 +02:00
|
|
|
package aws
|
|
|
|
|
|
|
|
import (
|
2016-07-11 23:10:13 +02:00
|
|
|
"testing"
|
2016-07-06 12:21:47 +02:00
|
|
|
|
2016-07-11 23:10:13 +02:00
|
|
|
"github.com/hashicorp/terraform/helper/resource"
|
2016-07-06 12:21:47 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
func TestAccAWSAPIGatewayApiKey_importBasic(t *testing.T) {
|
2016-07-11 23:10:13 +02:00
|
|
|
resourceName := "aws_api_gateway_api_key.test"
|
2016-07-06 12:21:47 +02:00
|
|
|
|
2016-07-11 23:10:13 +02:00
|
|
|
resource.Test(t, resource.TestCase{
|
|
|
|
PreCheck: func() { testAccPreCheck(t) },
|
|
|
|
Providers: testAccProviders,
|
|
|
|
CheckDestroy: testAccCheckAWSAPIGatewayApiKeyDestroy,
|
|
|
|
Steps: []resource.TestStep{
|
|
|
|
resource.TestStep{
|
|
|
|
Config: testAccAWSAPIGatewayApiKeyConfig,
|
|
|
|
},
|
2016-07-06 12:21:47 +02:00
|
|
|
|
2016-07-11 23:10:13 +02:00
|
|
|
resource.TestStep{
|
|
|
|
ResourceName: resourceName,
|
|
|
|
ImportState: true,
|
|
|
|
ImportStateVerify: true,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
})
|
2016-07-06 12:21:47 +02:00
|
|
|
}
|