test: drop unused code
This commit is contained in:
parent
830bc2df3b
commit
49c71f923b
|
@ -4,7 +4,6 @@ import (
|
|||
"fmt"
|
||||
"io/ioutil"
|
||||
"math/rand"
|
||||
"net"
|
||||
"os"
|
||||
"strings"
|
||||
"sync/atomic"
|
||||
|
@ -35,7 +34,6 @@ type agentWrapper struct {
|
|||
config *agent.Config
|
||||
agent *agent.Agent
|
||||
http *agent.HTTPServer
|
||||
addr string
|
||||
httpAddr string
|
||||
}
|
||||
|
||||
|
@ -63,13 +61,7 @@ func testAgentWithConfig(t *testing.T, cb func(c *agent.Config)) *agentWrapper {
|
|||
}
|
||||
|
||||
func testAgentWithConfigReload(t *testing.T, cb func(c *agent.Config), reloadCh chan chan error) *agentWrapper {
|
||||
l, err := net.Listen("tcp", "127.0.0.1:0")
|
||||
if err != nil {
|
||||
t.Fatalf("err: %s", err)
|
||||
}
|
||||
|
||||
lw := logger.NewLogWriter(512)
|
||||
|
||||
conf := nextConfig()
|
||||
if cb != nil {
|
||||
cb(conf)
|
||||
|
@ -105,7 +97,6 @@ func testAgentWithConfigReload(t *testing.T, cb func(c *agent.Config), reloadCh
|
|||
config: conf,
|
||||
agent: a,
|
||||
http: http[0],
|
||||
addr: l.Addr().String(),
|
||||
httpAddr: httpAddr,
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue