fix(tests): cover regex matches in silence tests

This commit is contained in:
Łukasz Mierzwa
2018-09-02 18:02:58 +01:00
parent a95b919872
commit bd4e549b27
2 changed files with 8 additions and 0 deletions

View File

@@ -112,6 +112,9 @@ exports[`<Silence /> matches snapshot with expaned details 1`] = `
<span class=\\"badge badge-success text-nowrap text-truncate px-1 mr-1\\">
alertname=MockAlert
</span>
<span class=\\"badge badge-success text-nowrap text-truncate px-1 mr-1\\">
instance=~foo[0-9]+
</span>
</div>
</div>
"

View File

@@ -30,6 +30,11 @@ const silence = {
name: "alertname",
value: "MockAlert",
isRegex: false
},
{
name: "instance",
value: "foo[0-9]+",
isRegex: true
}
],
startsAt: "2000-01-01T10:00:00Z",