The TestDockerNetworkIPAMMultipleNetworks test allocates several
networks simultaneously with overlapping IP addresses. Libnetwork now
forbids this. Adjust the test case to use distinct IP ranges for the
networks it creates.
Signed-off-by: Chris Telfer <ctelfer@docker.com>
| ... | ... |
@@ -610,17 +610,17 @@ func (s *DockerNetworkSuite) TestDockerNetworkIPAMMultipleNetworks(c *check.C) {
|
| 610 | 610 |
// test network with multiple subnets |
| 611 | 611 |
// bridge network doesn't support multiple subnets. hence, use a dummy driver that supports |
| 612 | 612 |
|
| 613 |
- dockerCmd(c, "network", "create", "-d", dummyNetworkDriver, "--subnet=192.168.0.0/16", "--subnet=192.170.0.0/16", "test6") |
|
| 613 |
+ dockerCmd(c, "network", "create", "-d", dummyNetworkDriver, "--subnet=192.170.0.0/16", "--subnet=192.171.0.0/16", "test6") |
|
| 614 | 614 |
assertNwIsAvailable(c, "test6") |
| 615 | 615 |
|
| 616 | 616 |
// test network with multiple subnets with valid ipam combinations |
| 617 | 617 |
// also check same subnet across networks when the driver supports it. |
| 618 | 618 |
dockerCmd(c, "network", "create", "-d", dummyNetworkDriver, |
| 619 |
- "--subnet=192.168.0.0/16", "--subnet=192.170.0.0/16", |
|
| 620 |
- "--gateway=192.168.0.100", "--gateway=192.170.0.100", |
|
| 621 |
- "--ip-range=192.168.1.0/24", |
|
| 622 |
- "--aux-address", "a=192.168.1.5", "--aux-address", "b=192.168.1.6", |
|
| 623 |
- "--aux-address", "c=192.170.1.5", "--aux-address", "d=192.170.1.6", |
|
| 619 |
+ "--subnet=192.172.0.0/16", "--subnet=192.173.0.0/16", |
|
| 620 |
+ "--gateway=192.172.0.100", "--gateway=192.173.0.100", |
|
| 621 |
+ "--ip-range=192.172.1.0/24", |
|
| 622 |
+ "--aux-address", "a=192.172.1.5", "--aux-address", "b=192.172.1.6", |
|
| 623 |
+ "--aux-address", "c=192.173.1.5", "--aux-address", "d=192.173.1.6", |
|
| 624 | 624 |
"test7") |
| 625 | 625 |
assertNwIsAvailable(c, "test7") |
| 626 | 626 |
|