diff options
author | Kevin Krakauer <krakauer@google.com> | 2020-01-21 13:16:25 -0800 |
---|---|---|
committer | Kevin Krakauer <krakauer@google.com> | 2020-01-21 13:16:25 -0800 |
commit | 62357a0afb5f4128a11dc9a1dfadd2957ec39e2d (patch) | |
tree | 2f93dc1bb5680434f3bcd69df60d45af89777a94 /test/iptables/iptables_test.go | |
parent | bd292894097ffdf316bc78d81aebd0a2988124f3 (diff) | |
parent | 2ba6198851dc1e293295d7cadf8c0ae456b68beb (diff) |
Merge branch 'master' into iptables-write-filter-proto
Diffstat (limited to 'test/iptables/iptables_test.go')
-rw-r--r-- | test/iptables/iptables_test.go | 38 |
1 files changed, 37 insertions, 1 deletions
diff --git a/test/iptables/iptables_test.go b/test/iptables/iptables_test.go index 635beea36..63e691af6 100644 --- a/test/iptables/iptables_test.go +++ b/test/iptables/iptables_test.go @@ -28,7 +28,7 @@ import ( "gvisor.dev/gvisor/runsc/testutil" ) -const timeout time.Duration = 10 * time.Second +const timeout = 18 * time.Second var image = flag.String("image", "bazel/test/iptables/runner:runner", "image to run tests in") @@ -189,3 +189,39 @@ func TestFilterInputDropOnlyUDP(t *testing.T) { t.Fatal(err) } } + +func TestNATRedirectUDPPort(t *testing.T) { + if err := singleTest(NATRedirectUDPPort{}); err != nil { + t.Fatal(err) + } +} + +func TestNATDropUDP(t *testing.T) { + if err := singleTest(NATDropUDP{}); err != nil { + t.Fatal(err) + } +} + +func TestFilterInputDropTCPDestPort(t *testing.T) { + if err := singleTest(FilterInputDropTCPDestPort{}); err != nil { + t.Fatal(err) + } +} + +func TestFilterInputDropTCPSrcPort(t *testing.T) { + if err := singleTest(FilterInputDropTCPSrcPort{}); err != nil { + t.Fatal(err) + } +} + +func TestFilterOutputDropTCPDestPort(t *testing.T) { + if err := singleTest(FilterOutputDropTCPDestPort{}); err != nil { + t.Fatal(err) + } +} + +func TestFilterOutputDropTCPSrcPort(t *testing.T) { + if err := singleTest(FilterOutputDropTCPSrcPort{}); err != nil { + t.Fatal(err) + } +} |