Remove useles balancer test

This commit is contained in:
DanB
2016-08-27 17:48:58 +02:00
parent 64ac51ad62
commit 474580540c

View File

@@ -51,26 +51,3 @@ func TestOneBalancer(t *testing.T) {
t.Error("With only one rater these shoud be equal")
}
}
func Test100Balancer(t *testing.T) {
balancer := NewBalancer()
var clients []Worker
for i := 0; i < 100; i++ {
c := new(rpc.Client)
balancer.AddClient(fmt.Sprintf("client%v", i), c)
}
for i := 0; i < 100; i++ {
c := balancer.Balance()
if c == nil {
t.Error("Retuned nil client!")
}
for _, o := range clients {
if c == o {
t.Error("Balance did not iterate all the available clients")
break
}
}
clients = append(clients, c)
}
}