aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2018-11-08 13:58:19 -0800
committerDamjan Marion <dmarion@me.com>2018-11-09 11:24:53 +0000
commita8f53818e20ba5252ecd2067ecf71a55139ae874 (patch)
tree1a688a830631e8609ba4740e41c0fde659cb7c77 /test
parent2e31cc35ca5db7f16c8052578d79f1ec84c0acb5 (diff)
tcp: separate unit and throughput tests
Change-Id: I249e68874dcf38b07179e0e769f6eb49a43377b7 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'test')
-rw-r--r--test/test_tcp.py28
1 files changed, 20 insertions, 8 deletions
diff --git a/test/test_tcp.py b/test/test_tcp.py
index 4a5c9bc4ff3..ff231341001 100644
--- a/test/test_tcp.py
+++ b/test/test_tcp.py
@@ -45,14 +45,6 @@ class TestTCP(VppTestCase):
self.vapi.session_enable_disable(is_enabled=0)
super(TestTCP, self).tearDown()
- def test_tcp_unittest(self):
- """ TCP Unit Tests """
- error = self.vapi.cli("test tcp all")
-
- if error:
- self.logger.critical(error)
- self.assertEqual(error.find("failed"), -1)
-
def test_tcp_transfer(self):
""" TCP echo client/server transfer """
@@ -87,5 +79,25 @@ class TestTCP(VppTestCase):
ip_t01.remove_vpp_config()
ip_t10.remove_vpp_config()
+
+class TestTCPUnitTests(VppTestCase):
+ "TCP Unit Tests"
+
+ def setUp(self):
+ super(TestTCPUnitTests, self).setUp()
+ self.vapi.session_enable_disable(is_enabled=1)
+
+ def tearDown(self):
+ super(TestTCPUnitTests, self).tearDown()
+ self.vapi.session_enable_disable(is_enabled=0)
+
+ def test_tcp_unittest(self):
+ """ TCP Unit Tests """
+ error = self.vapi.cli("test tcp all")
+
+ if error:
+ self.logger.critical(error)
+ self.assertEqual(error.find("failed"), -1)
+
if __name__ == '__main__':
unittest.main(testRunner=VppTestRunner)