Skip to content

Commit ebf1689

Browse files
test: add resource type filter to alerts test (#46)
1 parent 748f0d9 commit ebf1689

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

monitoring/snippets/system-test/alerts.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ test.before(async () => {
4444
{
4545
displayName: 'Condition 1',
4646
conditionAbsent: {
47-
filter: `metric.type = "cloudfunctions.googleapis.com/function/execution_count"`,
47+
filter: `resource.type = "cloud_function" AND metric.type = "cloudfunctions.googleapis.com/function/execution_count"`,
4848
aggregations: [
4949
{
5050
alignmentPeriod: {
@@ -75,7 +75,7 @@ test.before(async () => {
7575
{
7676
displayName: 'Condition 2',
7777
conditionAbsent: {
78-
filter: `metric.type = "cloudfunctions.googleapis.com/function/execution_count"`,
78+
filter: `resource.type = "cloud_function" AND metric.type = "cloudfunctions.googleapis.com/function/execution_count"`,
7979
aggregations: [
8080
{
8181
alignmentPeriod: {

0 commit comments

Comments
 (0)