aboutsummaryrefslogtreecommitdiffstats
path: root/extras/hs-test/vcl_test.go
diff options
context:
space:
mode:
authorMaros Ondrejicka <maros.ondrejicka@pantheon.tech>2022-12-19 20:35:27 +0100
committerFlorin Coras <florin.coras@gmail.com>2022-12-20 18:49:49 +0000
commit8753180a80e03dd031fa7f470adbcbb4a611d1c9 (patch)
treef524d7f4261b5db5861ee7e83822d99ab63f3262 /extras/hs-test/vcl_test.go
parent8c626b41eaab5c74e7e023205f1c6cd655d40f44 (diff)
hs-test: add runtime options
Options "-p" to not remove topology elements after the test finishes "-v" from now on extra output from tests is hidden by default, this will show it again Type: test Signed-off-by: Maros Ondrejicka <maros.ondrejicka@pantheon.tech> Change-Id: I626188561c883534e9004d5130ee2a972d12b4e2
Diffstat (limited to 'extras/hs-test/vcl_test.go')
-rwxr-xr-xextras/hs-test/vcl_test.go23
1 files changed, 11 insertions, 12 deletions
diff --git a/extras/hs-test/vcl_test.go b/extras/hs-test/vcl_test.go
index 80775542712..5a5ba06bebc 100755
--- a/extras/hs-test/vcl_test.go
+++ b/extras/hs-test/vcl_test.go
@@ -1,17 +1,16 @@
package main
import (
- "fmt"
"time"
)
func (s *VethsSuite) TestVclEchoQuic() {
- s.T().Skip("quic test skipping..")
+ s.skip("quic test skipping..")
s.testVclEcho("quic")
}
func (s *VethsSuite) TestVclEchoUdp() {
- s.T().Skip("udp echo currently broken in vpp, skipping..")
+ s.skip("udp echo currently broken in vpp, skipping..")
s.testVclEcho("udp")
}
@@ -41,11 +40,11 @@ func (s *VethsSuite) testVclEcho(proto string) {
o, err := echoClnContainer.execAction("RunEchoClient "+proto)
s.assertNil(err)
- fmt.Println(o)
+ s.log(o)
}
func (s *VethsSuite) TestVclRetryAttach() {
- s.T().Skip()
+ s.skip()
s.testRetryAttach("tcp")
}
@@ -64,12 +63,12 @@ func (s *VethsSuite) testRetryAttach(proto string) {
_, err = echoSrvContainer.execAction("RunVclEchoServer "+proto)
s.assertNil(err)
- fmt.Println("This whole test case can take around 3 minutes to run. Please be patient.")
- fmt.Println("... Running first echo client test, before disconnect.")
+ s.log("This whole test case can take around 3 minutes to run. Please be patient.")
+ s.log("... Running first echo client test, before disconnect.")
echoClnContainer := s.getContainerByName("client-application")
_, err = echoClnContainer.execAction("RunVclEchoClient "+proto)
s.assertNil(err)
- fmt.Println("... First test ended. Stopping VPP server now.")
+ s.log("... First test ended. Stopping VPP server now.")
// Stop server-vpp-instance, start it again and then run vcl-test-client once more
stopVppCommand := "/bin/bash -c 'ps -C vpp_main -o pid= | xargs kill -9'"
@@ -82,13 +81,13 @@ func (s *VethsSuite) testRetryAttach(proto string) {
_, err = srvVppContainer.execAction("Configure2Veths srv-with-preset-hw-addr")
s.assertNil(err)
- fmt.Println("... VPP server is starting again, so waiting for a bit.")
+ s.log("... VPP server is starting again, so waiting for a bit.")
time.Sleep(30 * time.Second) // Wait a moment for the re-attachment to happen
- fmt.Println("... Running second echo client test, after disconnect and re-attachment.")
+ s.log("... Running second echo client test, after disconnect and re-attachment.")
_, err = echoClnContainer.execAction("RunVclEchoClient "+proto)
s.assertNil(err)
- fmt.Println("Done.")
+ s.log("Done.")
}
func (s *VethsSuite) TestTcpWithLoss() {
@@ -127,5 +126,5 @@ func (s *VethsSuite) TestTcpWithLoss() {
s.assertNil(err)
s.assertEqual(true, len(output) != 0)
s.assertNotContains(output, "failed: timeout")
- fmt.Println(output)
+ s.log(output)
}