Skip to content

Commit

Permalink
e2e: fix exlcudeIps
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangzujian committed Jun 29, 2023
1 parent 4e7d718 commit 7634bc5
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/e2e/kube-ovn/ipam/ipam.go
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,15 @@ var _ = framework.Describe("[group:ipam]", func() {
ipv6Range, err := ipam.NewIPRangeListFrom(ipv6...)
framework.ExpectNoError(err)

excludeV4, excludeV6 := util.SplitIpsByProtocol(subnet.Spec.ExcludeIps)
excludeV4Range, err := ipam.NewIPRangeListFrom(excludeV4...)
framework.ExpectNoError(err)
excludeV6Range, err := ipam.NewIPRangeListFrom(excludeV6...)
framework.ExpectNoError(err)

ipv4Range = ipv4Range.Separate(excludeV4Range)
ipv6Range = ipv6Range.Separate(excludeV6Range)

ginkgo.By(fmt.Sprintf("Creating ippool %s with ips %v", ippoolName, ips))
ippool := framework.MakeIPPool(ippoolName, subnetName, ips, nil)
ippool = ippoolClient.CreateSync(ippool)
Expand Down

0 comments on commit 7634bc5

Please sign in to comment.