From aa419cef4b0189d0dbe739e65553482a135cd5d1 Mon Sep 17 00:00:00 2001 From: Zeling Feng Date: Tue, 1 Dec 2020 18:52:02 -0800 Subject: Avoid wrong error messages Stop showing wrong timeout values in packetimpact test error messages. e.g. "got frames ... want ... during -123ms" PiperOrigin-RevId: 345144938 --- test/packetimpact/testbench/connections.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/packetimpact/testbench/connections.go b/test/packetimpact/testbench/connections.go index 266a8601c..50b9ccf68 100644 --- a/test/packetimpact/testbench/connections.go +++ b/test/packetimpact/testbench/connections.go @@ -598,7 +598,7 @@ func (conn *Connection) ExpectFrame(t *testing.T, layers Layers, timeout time.Du var errs error for { var gotLayers Layers - if timeout = time.Until(deadline); timeout > 0 { + if timeout := time.Until(deadline); timeout > 0 { gotLayers = conn.recvFrame(t, timeout) } if gotLayers == nil { -- cgit v1.2.3