package digitalocean import ( "testing" "github.com/hashicorp/terraform/helper/resource" ) func TestAccDigitalOceanDroplet_importBasic(t *testing.T) { resourceName := "digitalocean_droplet.foobar" resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, Providers: testAccProviders, CheckDestroy: testAccCheckDigitalOceanDropletDestroy, Steps: []resource.TestStep{ resource.TestStep{ Config: testAccCheckDigitalOceanDropletConfig_basic, }, resource.TestStep{ ResourceName: resourceName, ImportState: true, ImportStateVerify: true, ImportStateVerifyIgnore: []string{ "ssh_keys", "user_data"}, //we ignore the ssh_keys and user_data as we do not set to state }, }, }) }