Skip to content

Commit 0adfa17

Browse files
authored
Fix monitoring tests (#799)
* Fix monitoring tests
1 parent 8679220 commit 0adfa17

File tree

3 files changed

+2
-5
lines changed

3 files changed

+2
-5
lines changed

monitoring/api/v3/cloud-client/quickstart.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,7 @@ def run_quickstart():
2929

3030
metric = client.metric(
3131
type_='custom.googleapis.com/my_metric',
32-
labels={
33-
'status': 'successful',
34-
}
32+
labels={}
3533
)
3634

3735
client.write_point(metric, resource, 3.14)

monitoring/api/v3/cloud-client/snippets.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ def write_time_series():
5454
metric = client.metric(
5555
type_='custom.googleapis.com/my_metric',
5656
labels={
57-
'status': 'successful',
5857
}
5958
)
6059
client.write_point(metric, resource, 3.14)

monitoring/api/v3/cloud-client/snippets_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def test_create_get_delete_metric_descriptor(capsys):
1919
snippets.create_metric_descriptor()
2020
snippets.get_metric_descriptor('custom.googleapis.com/my_metric')
2121
out, _ = capsys.readouterr()
22-
assert 'a simple example' in out
22+
assert "value_type='DOUBLE'" in out
2323
snippets.delete_metric_descriptor('custom.googleapis.com/my_metric')
2424
out, _ = capsys.readouterr()
2525
assert 'Deleted metric' in out

0 commit comments

Comments
 (0)