From 712b3e74b65cc3b406ddd4d87264a931f3960c55 Mon Sep 17 00:00:00 2001 From: Jake Champlin Date: Tue, 10 Jan 2017 10:00:04 -0500 Subject: [PATCH] provider/digitalocean: Fix failing acceptance test The second step of the `TestAccDigitalOceanDroplet_ResizeWithOutDisk` acceptance test was regularly failing. Upon investigation it was found that the second step's Terraform configuration had omitted the `user_data` parameter, thus forcing Terraform to create a new droplet resource instead of updating the current resource. ``` -/+ digitalocean_droplet.foobar disk: "20" => "" image: "centos-7-x64" => "centos-7-x64" ipv4_address: "138.197.0.55" => "" ipv4_address_private: "" => "" ipv6_address: "" => "" ipv6_address_private: "" => "" locked: "false" => "" name: "foo" => "foo" region: "nyc3" => "nyc3" resize_disk: "true" => "false" size: "512mb" => "1gb" ssh_keys.#: "1" => "1" ssh_keys.0: "5770472" => "5770472" status: "active" => "" user_data: "foobar" => "" (forces new resource) vcpus: "1" => "" ``` This fixes the acceptance test by adding the missing `user_data` parameter. --- .../providers/digitalocean/resource_digitalocean_droplet_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/builtin/providers/digitalocean/resource_digitalocean_droplet_test.go b/builtin/providers/digitalocean/resource_digitalocean_droplet_test.go index 53a6abeca..693630145 100644 --- a/builtin/providers/digitalocean/resource_digitalocean_droplet_test.go +++ b/builtin/providers/digitalocean/resource_digitalocean_droplet_test.go @@ -450,6 +450,7 @@ resource "digitalocean_droplet" "foobar" { size = "1gb" image = "centos-7-x64" region = "nyc3" + user_data = "foobar" ssh_keys = ["${digitalocean_ssh_key.foobar.id}"] resize_disk = false }