Skip to content

Commit

Permalink
Whitespace changes from go fmt
Browse files Browse the repository at this point in the history
Signed-off-by: Todd Ekenstam <Todd_Ekenstam@intuit.com>
  • Loading branch information
tekenstam committed Sep 14, 2023
1 parent 88f1d12 commit 20545a1
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 14 deletions.
2 changes: 1 addition & 1 deletion pkg/reaper/common/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ package common
type MetricsAPI interface {
// Set Metric value on metric
SetMetricValue(metricName string, tags map[string]string, value float64) error
}
}
2 changes: 1 addition & 1 deletion pkg/reaper/common/prom_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ func TestAPIs(t *testing.T) {

err := api.SetMetricValue("abc", tags, 50)
assert.Nil(t, err)
}
}
2 changes: 1 addition & 1 deletion pkg/reaper/nodereaper/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ func getNodeAgeMinutes(n *v1.Node) int {
}

func getNodeRegion(n *v1.Node) string {
var regionName = ""
var regionName = ""
labels := n.GetLabels()
if labels != nil {
regionName = labels["topology.kubernetes.io/region"]
Expand Down
19 changes: 9 additions & 10 deletions pkg/reaper/nodereaper/nodereaper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1335,13 +1335,13 @@ func TestIgnoreFailure(t *testing.T) {
},
Nodes: []FakeNode{
{
nodeName: "ip-10-10-10-10.us-west-2.compute.local",
state: "NotReady",
nodeName: "ip-10-10-10-10.us-west-2.compute.local",
state: "NotReady",
ageMinutes: 43200,
},
{
nodeName: "ip-10-10-10-11.us-west-2.compute.local",
state: "Unknown",
nodeName: "ip-10-10-10-11.us-west-2.compute.local",
state: "Unknown",
ageMinutes: 43200,
},
{
Expand All @@ -1363,11 +1363,11 @@ func TestIgnoreFailure(t *testing.T) {
kind: "Node",
},
},
FakeReaper: reaper,
ExpectedUnready: 3,
ExpectedOldReapable: 3,
ExpectedDrainable: 0,
ExpectedDrained: 0,
FakeReaper: reaper,
ExpectedUnready: 3,
ExpectedOldReapable: 3,
ExpectedDrainable: 0,
ExpectedDrained: 0,
}
testCase.Run(t, false)
}
Expand Down Expand Up @@ -1727,7 +1727,6 @@ func TestRegionDetection(t *testing.T) {
}
}


func TestSkipLabelReaper(t *testing.T) {
reaper := newFakeReaperContext()
reaper.ReapUnknown = true
Expand Down
2 changes: 1 addition & 1 deletion pkg/reaper/pdbreaper/pdbreaper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -649,4 +649,4 @@ func TestWithPushgateway(t *testing.T) {
ExpectedReapedBudgets: 0,
}
testCase.Run(t)
}
}

0 comments on commit 20545a1

Please sign in to comment.