Skip to content

Commit 9dc099c

Browse files
committed
fix image to be empty
1 parent 72cd8e4 commit 9dc099c

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

mmv1/third_party/terraform/services/compute/resource_compute_disk_test.go.tmpl

+10-2
Original file line numberDiff line numberDiff line change
@@ -966,7 +966,7 @@ func TestAccComputeDisk_sourceStorageObject(t *testing.T) {
966966

967967
context := map[string]interface{}{
968968
"random_suffix": acctest.RandString(t, 10),
969-
"source_storage_object": "",
969+
"source_storage_object": "test-fixtures/empty-image.tar.gz",
970970
}
971971

972972
var disk compute.Disk
@@ -2061,12 +2061,20 @@ resource "google_storage_bucket" "bucket" {
20612061
location = "US"
20622062
}
20632063

2064+
resource "google_storage_bucket_object" "object" {
2065+
name = "tf-test-object-%{random_suffix}.tar.gz"
2066+
bucket = google_storage_bucket.bucket.name
2067+
source = "%{source_storage_object}"
2068+
}
2069+
20642070
resource "google_compute_disk" "foobar" {
20652071
name = "tf-test-disk-%{random_suffix}"
20662072
type = "pd-ssd"
20672073
size = 10
20682074
zone = "us-central1-a"
2069-
source_storage_object = "%{source_storage_object}"
2075+
source_storage_object = "gs://${google_storage_bucket.bucket.name}/${google_storage_bucket_object.object.name}"
2076+
2077+
depends_on = [google_storage_bucket_object.object]
20702078
}
20712079
`, context)
20722080
}
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)