@@ -11,8 +11,6 @@ import (
11
11
)
12
12
13
13
func TestAccMonitoringMetricDescriptor_update (t * testing.T ) {
14
- // TODO: Fix requires a breaking change https://github.com/hashicorp/terraform-provider-google/issues/12139
15
- t .Skip ()
16
14
17
15
t .Parallel ()
18
16
acctest .VcrTest (t , resource.TestCase {
@@ -21,8 +19,7 @@ func TestAccMonitoringMetricDescriptor_update(t *testing.T) {
21
19
CheckDestroy : testAccCheckMonitoringMetricDescriptorDestroyProducer (t ),
22
20
Steps : []resource.TestStep {
23
21
{
24
- Config : testAccMonitoringMetricDescriptor_update ("key1" , "STRING" ,
25
- "description1" , "30s" , "30s" ),
22
+ Config : testAccMonitoringMetricDescriptor_update ("30s" , "30s" ),
26
23
},
27
24
{
28
25
ResourceName : "google_monitoring_metric_descriptor.basic" ,
@@ -31,8 +28,7 @@ func TestAccMonitoringMetricDescriptor_update(t *testing.T) {
31
28
ImportStateVerifyIgnore : []string {"metadata" , "launch_stage" },
32
29
},
33
30
{
34
- Config : testAccMonitoringMetricDescriptor_update ("key2" , "INT64" ,
35
- "description2" , "60s" , "60s" ),
31
+ Config : testAccMonitoringMetricDescriptor_update ("60s" , "60s" ),
36
32
},
37
33
{
38
34
ResourceName : "google_monitoring_metric_descriptor.basic" ,
@@ -44,8 +40,7 @@ func TestAccMonitoringMetricDescriptor_update(t *testing.T) {
44
40
})
45
41
}
46
42
47
- func testAccMonitoringMetricDescriptor_update (key , valueType , description ,
48
- samplePeriod , ingestDelay string ) string {
43
+ func testAccMonitoringMetricDescriptor_update (samplePeriod , ingestDelay string ) string {
49
44
return fmt .Sprintf (`
50
45
resource "google_monitoring_metric_descriptor" "basic" {
51
46
description = "Daily sales records from all branch stores."
@@ -55,16 +50,16 @@ resource "google_monitoring_metric_descriptor" "basic" {
55
50
value_type = "DOUBLE"
56
51
unit = "{USD}"
57
52
labels {
58
- key = "%s "
59
- value_type = "%s "
60
- description = "%s "
53
+ key = "key "
54
+ value_type = "STRING "
55
+ description = "description "
61
56
}
62
57
launch_stage = "BETA"
63
58
metadata {
64
59
sample_period = "%s"
65
60
ingest_delay = "%s"
66
61
}
67
62
}
68
- ` , key , valueType , description , samplePeriod , ingestDelay ,
63
+ ` , samplePeriod , ingestDelay ,
69
64
)
70
65
}
0 commit comments