summaryrefslogtreecommitdiffhomepage
path: root/test/packetimpact/tests
diff options
context:
space:
mode:
authorAdin Scannell <ascannell@google.com>2020-08-04 20:49:00 -0700
committerAdin Scannell <ascannell@google.com>2020-08-04 20:49:00 -0700
commitc5f5806fe69e8d4be99341318f20ce0acfd7be2a (patch)
treea67130ecf0cc3f404fd0952b9cb743f0854991e8 /test/packetimpact/tests
parentaf2f456735252b8412af676a3d6ff61690fdf9a7 (diff)
Enable "make packetimpact-tests" to work.
This required minor fixes to the bazel wrapper. The "dut_platform" is also changed to "native" to line-up with the system call tests and remove the hard-coded "linux" and "netstack" strings.
Diffstat (limited to 'test/packetimpact/tests')
-rw-r--r--test/packetimpact/tests/tcp_reordering_test.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/packetimpact/tests/tcp_reordering_test.go b/test/packetimpact/tests/tcp_reordering_test.go
index 8742819ca..b4aeaab57 100644
--- a/test/packetimpact/tests/tcp_reordering_test.go
+++ b/test/packetimpact/tests/tcp_reordering_test.go
@@ -54,13 +54,13 @@ func TestReorderingWindow(t *testing.T) {
acceptFd, _ := dut.Accept(t, listenFd)
defer dut.Close(t, acceptFd)
- if tb.DUTType == "linux" {
+ if tb.Native {
// Linux has changed its handling of reordering, force the old behavior.
dut.SetSockOpt(t, acceptFd, unix.IPPROTO_TCP, unix.TCP_CONGESTION, []byte("reno"))
}
pls := dut.GetSockOptInt(t, acceptFd, unix.IPPROTO_TCP, unix.TCP_MAXSEG)
- if tb.DUTType == "netstack" {
+ if !tb.Native {
// netstack does not impliment TCP_MAXSEG correctly. Fake it
// here. Netstack uses the max SACK size which is 32. The MSS
// option is 8 bytes, making the total 36 bytes.
@@ -141,7 +141,7 @@ func TestReorderingWindow(t *testing.T) {
}
}
- if tb.DUTType == "netstack" {
+ if !tb.Native {
// The window should now be halved, so we should receive any
// more, even if we send them.
dut.Send(t, acceptFd, payload, 0)