Skip to content

Commit

Permalink
fix: handled review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Hardikl committed Feb 23, 2023
1 parent f104c08 commit 9724973
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/tools/grafana/dashboard_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,8 @@ func doPanel(t *testing.T, pathPrefix string, key gjson.Result, value gjson.Resu

// In case of gradient-gauge and percent(0.0-1.0), we must override min and max value
for _, properties := range propertiesMap {
if properties["unit"] == "percentunit" && properties["custom.displayMode"] == "gradient-gauge" {
displayMode := properties["custom.displayMode"]
if properties["unit"] == "percentunit" && (displayMode == "gradient-gauge" || displayMode == "lcd-gauge" || displayMode == "basic") {
if maxVal, exist := properties["max"]; !exist || maxVal != "1" {
t.Errorf("dashboard=%s, title=%s should have max value 1", sPath, title)
}
Expand Down

0 comments on commit 9724973

Please sign in to comment.