@ -125,6 +125,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -179,6 +180,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label_1" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -202,6 +204,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label_2" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
Results : [ ] state . Evaluation {
{
@ -259,6 +262,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -320,6 +324,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
Results : [ ] state . Evaluation {
{
@ -392,6 +397,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
Results : [ ] state . Evaluation {
{
@ -486,6 +492,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Pending ,
Results : [ ] state . Evaluation {
{
@ -567,6 +574,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . NoData ,
Results : [ ] state . Evaluation {
{
@ -631,6 +639,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Pending ,
Results : [ ] state . Evaluation {
{
@ -695,6 +704,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Pending ,
Results : [ ] state . Evaluation {
{
@ -759,6 +769,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
StateReason : eval . NoData . String ( ) ,
Results : [ ] state . Evaluation {
@ -824,6 +835,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . NoData ,
Results : [ ] state . Evaluation {
{
@ -888,6 +900,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -912,6 +925,7 @@ func TestProcessEvalResults(t *testing.T) {
"alertname" : "test_title" ,
"label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . NoData ,
Results : [ ] state . Evaluation {
{
@ -977,6 +991,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test-1" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -1002,6 +1017,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test-2" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -1026,6 +1042,7 @@ func TestProcessEvalResults(t *testing.T) {
"alertname" : "test_title" ,
"label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . NoData ,
Results : [ ] state . Evaluation {
{
@ -1093,6 +1110,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -1122,6 +1140,7 @@ func TestProcessEvalResults(t *testing.T) {
"alertname" : "test_title" ,
"label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . NoData ,
Results : [ ] state . Evaluation {
{
@ -1181,6 +1200,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
StateReason : eval . NoData . String ( ) ,
Results : [ ] state . Evaluation {
@ -1247,6 +1267,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
StateReason : eval . NoData . String ( ) ,
@ -1314,6 +1335,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Pending ,
StateReason : eval . Error . String ( ) ,
Results : [ ] state . Evaluation {
@ -1404,6 +1426,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
StateReason : eval . Error . String ( ) ,
Results : [ ] state . Evaluation {
@ -1485,6 +1508,7 @@ func TestProcessEvalResults(t *testing.T) {
"datasource_uid" : "datasource_uid_1" ,
"ref_id" : "A" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Error ,
Error : expr . QueryError {
RefID : "A" ,
@ -1562,6 +1586,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
StateReason : eval . Error . String ( ) ,
Error : nil ,
@ -1635,6 +1660,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
StateReason : eval . Error . String ( ) ,
Error : nil ,
@ -1734,6 +1760,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Error ,
Results : [ ] state . Evaluation {
{
@ -1815,6 +1842,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Alerting ,
Results : [ ] state . Evaluation {
{
@ -1902,6 +1930,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"instance_label" : "test" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . NoData ,
Results : [ ] state . Evaluation {
{
@ -1964,6 +1993,7 @@ func TestProcessEvalResults(t *testing.T) {
"label" : "test" ,
"job" : "prod/grafana" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{
@ -2117,6 +2147,7 @@ func TestStaleResultsHandler(t *testing.T) {
"alertname" : rule . Title ,
"test1" : "testValue1" ,
} ,
Values : make ( map [ string ] float64 ) ,
State : eval . Normal ,
Results : [ ] state . Evaluation {
{