Ignore server for container with empty IP address.
This commit is contained in:
parent
5924a40222
commit
7ef8d6fa10
4 changed files with 145 additions and 2 deletions
|
@ -832,6 +832,18 @@ func TestGetServers(t *testing.T) {
|
|||
},
|
||||
expected: nil,
|
||||
},
|
||||
{
|
||||
desc: "should return nil when no server IPs",
|
||||
service: rancherData{
|
||||
Labels: map[string]string{
|
||||
label.TraefikWeight: "7",
|
||||
},
|
||||
Containers: []string{""},
|
||||
Health: "healthy",
|
||||
State: "active",
|
||||
},
|
||||
expected: nil,
|
||||
},
|
||||
{
|
||||
desc: "should use default weight when invalid weight value",
|
||||
service: rancherData{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue