You've already forked postgres_exporter
mirror of
https://github.com/prometheus-community/postgres_exporter.git
synced 2025-08-12 14:02:47 +03:00
Gofmt the code.
This commit is contained in:
@@ -11,16 +11,16 @@ import (
|
||||
|
||||
. "gopkg.in/check.v1"
|
||||
|
||||
"github.com/prometheus/client_golang/prometheus"
|
||||
"database/sql"
|
||||
_ "github.com/lib/pq"
|
||||
"fmt"
|
||||
_ "github.com/lib/pq"
|
||||
"github.com/prometheus/client_golang/prometheus"
|
||||
)
|
||||
|
||||
// Hook up gocheck into the "go test" runner.
|
||||
func Test(t *testing.T) { TestingT(t) }
|
||||
|
||||
type IntegrationSuite struct{
|
||||
type IntegrationSuite struct {
|
||||
e *Exporter
|
||||
}
|
||||
|
||||
@@ -43,7 +43,8 @@ func (s *IntegrationSuite) TestAllNamespacesReturnResults(c *C) {
|
||||
// Setup a dummy channel to consume metrics
|
||||
ch := make(chan prometheus.Metric, 100)
|
||||
go func() {
|
||||
for _ = range ch {}
|
||||
for range ch {
|
||||
}
|
||||
}()
|
||||
|
||||
// Open a database connection
|
||||
@@ -65,7 +66,6 @@ func (s *IntegrationSuite) TestAllNamespacesReturnResults(c *C) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// This should never happen in our test cases.
|
||||
errMap := queryNamespaceMappings(ch, db, s.e.metricMap, s.e.queryOverrides)
|
||||
if !c.Check(len(errMap), Equals, 0) {
|
||||
@@ -74,4 +74,4 @@ func (s *IntegrationSuite) TestAllNamespacesReturnResults(c *C) {
|
||||
fmt.Println(namespace, ":", err)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user