Skip to content

Commit

Permalink
wip test
Browse files Browse the repository at this point in the history
  • Loading branch information
emalloy committed Mar 25, 2019
1 parent 9465170 commit c56aaf0
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions examples/simple_regional/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ variable "cluster_resource_labels" {
description = "Map containing cluster labels. Maximum of 64 labels"

default = {
created-by = "terraform"
}

}
10 changes: 10 additions & 0 deletions test/fixtures/shared/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,13 @@ variable "zones" {
variable "compute_engine_service_account" {
description = "The email address of the service account to associate with the GKE cluster"
}

variable "cluster_resource_labels" {
type = "map"
description = "Map containing cluster labels. Maximum of 64 labels"

default = {
created-by = "terraform"
}
}

1 change: 1 addition & 0 deletions test/fixtures/simple_regional/example.tf
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,5 @@ module "example" {
ip_range_pods = "${google_compute_subnetwork.main.secondary_ip_range.0.range_name}"
ip_range_services = "${google_compute_subnetwork.main.secondary_ip_range.1.range_name}"
compute_engine_service_account = "${var.compute_engine_service_account}"
cluster_resource_labels = "${var.cluster_resource_labels}"
}
10 changes: 10 additions & 0 deletions test/integration/simple_regional/controls/gcloud.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,12 @@
},
})
end

it "has cluster resource labels" do
expect(data['resourceLabels']).to eq({
"created-by" => "terraform",
})
end
end

describe "default node pool" do
Expand Down Expand Up @@ -138,6 +144,10 @@
)
end





it "has the expected network tags" do
expect(node_pools).to include(
including(
Expand Down

0 comments on commit c56aaf0

Please sign in to comment.