package aws import ( "testing" "github.com/hashicorp/terraform/helper/acctest" "github.com/hashicorp/terraform/helper/resource" ) func TestAccAWSCloudWatchLogGroup_importBasic(t *testing.T) { resourceName := "aws_cloudwatch_log_group.foobar" rInt := acctest.RandInt() resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, Providers: testAccProviders, CheckDestroy: testAccCheckAWSCloudWatchLogGroupDestroy, Steps: []resource.TestStep{ resource.TestStep{ Config: testAccAWSCloudWatchLogGroupConfig(rInt), }, resource.TestStep{ ResourceName: resourceName, ImportState: true, ImportStateVerify: true, ImportStateVerifyIgnore: []string{"retention_in_days"}, //this has a default value }, }, }) }