Skip to content

Commit a997d7d

Browse files
committed
test/e2e: unskip netavark macvlan/ipvlan tests
These should all work with the latest netavark. The ipvlan case needs a subnet because it does not support DHCP. Signed-off-by: Paul Holzinger <[email protected]>
1 parent a2f0a44 commit a997d7d

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

test/e2e/network_test.go

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -506,8 +506,6 @@ var _ = Describe("Podman network", func() {
506506
})
507507

508508
It("podman network create/remove macvlan", func() {
509-
// Netavark currently does not do dhcp so the this test fails
510-
SkipIfNetavark(podmanTest)
511509
net := "macvlan" + stringid.GenerateRandomID()
512510
nc := podmanTest.Podman([]string{"network", "create", "--macvlan", "lo", net})
513511
nc.WaitWithDefaultTimeout()
@@ -521,8 +519,6 @@ var _ = Describe("Podman network", func() {
521519
})
522520

523521
It("podman network create/remove macvlan as driver (-d) no device name", func() {
524-
// Netavark currently does not do dhcp so the this test fails
525-
SkipIfNetavark(podmanTest)
526522
net := "macvlan" + stringid.GenerateRandomID()
527523
nc := podmanTest.Podman([]string{"network", "create", "-d", "macvlan", net})
528524
nc.WaitWithDefaultTimeout()
@@ -550,8 +546,6 @@ var _ = Describe("Podman network", func() {
550546
for _, opt := range []string{"-o=parent=lo", "--interface-name=lo"} {
551547
opt := opt
552548
It(fmt.Sprintf("podman network create/remove macvlan as driver (-d) with %s", opt), func() {
553-
// Netavark currently does not do dhcp so the this test fails
554-
SkipIfNetavark(podmanTest)
555549
net := "macvlan" + stringid.GenerateRandomID()
556550
nc := podmanTest.Podman([]string{"network", "create", "-d", "macvlan", opt, net})
557551
nc.WaitWithDefaultTimeout()
@@ -580,10 +574,8 @@ var _ = Describe("Podman network", func() {
580574
}
581575

582576
It("podman network create/remove ipvlan as driver (-d) with device name", func() {
583-
// Netavark currently does not support ipvlan
584-
SkipIfNetavark(podmanTest)
585577
net := "ipvlan" + stringid.GenerateRandomID()
586-
nc := podmanTest.Podman([]string{"network", "create", "-d", "ipvlan", "-o", "parent=lo", net})
578+
nc := podmanTest.Podman([]string{"network", "create", "-d", "ipvlan", "-o", "parent=lo", "--subnet", "10.0.2.0/24", net})
587579
nc.WaitWithDefaultTimeout()
588580
defer podmanTest.removeNetwork(net)
589581
Expect(nc).Should(ExitCleanly())
@@ -600,8 +592,8 @@ var _ = Describe("Podman network", func() {
600592

601593
Expect(result).To(HaveField("Driver", "ipvlan"))
602594
Expect(result).To(HaveField("NetworkInterface", "lo"))
603-
Expect(result.IPAMOptions).To(HaveKeyWithValue("driver", "dhcp"))
604-
Expect(result.Subnets).To(BeEmpty())
595+
Expect(result.IPAMOptions).To(HaveKeyWithValue("driver", "host-local"))
596+
Expect(result.Subnets).To(HaveLen(1))
605597

606598
nc = podmanTest.Podman([]string{"network", "rm", net})
607599
nc.WaitWithDefaultTimeout()

0 commit comments

Comments
 (0)