""" VCL Test Class """
def __init__(self, methodName):
- var = "VPP_TEST_BUILD_DIR"
+ var = "VPP_BUILD_DIR"
self.build_dir = os.getenv(var, None)
if self.build_dir is None:
raise Exception("Environment variable `%s' not set" % var)
worker_server = VCLAppWorker(self.build_dir, server_app, server_args,
self.logger, self.env)
worker_server.start()
- self.sleep(0.2)
+ self.sleep(0.3)
worker_client = VCLAppWorker(self.build_dir, client_app, client_args,
self.logger, self.env)
worker_client.start()
worker_server = VCLAppWorker(self.build_dir, server_app, server_args,
self.logger, self.env)
worker_server.start()
- self.sleep(0.2)
+ self.sleep(0.3)
self.env.update({'VCL_APP_NAMESPACE_ID': "2",
'VCL_APP_NAMESPACE_SECRET': "5678"})
self.assert_equal(worker_client.result, 0, "Binary test return code")
-class VCLCutThruTestCase(VCLTestCase):
- """ VCL Cut Thru Tests """
+class LDPCutThruTestCase(VCLTestCase):
+ """ LDP Cut Thru Tests """
def setUp(self):
- super(VCLCutThruTestCase, self).setUp()
+ super(LDPCutThruTestCase, self).setUp()
self.cut_thru_setup()
self.client_echo_test_args = ["-E", self.echo_phrase, "-X",
self.client_iperf3_timeout = 20
self.client_iperf3_args = ["-V4d", "-t 5", "-c", self.server_addr]
self.server_iperf3_args = ["-V4d", "-s"]
- self.client_uni_dir_nsock_timeout = 60
+ self.client_uni_dir_nsock_timeout = 20
self.client_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",
"-I", "2",
self.server_addr,
self.server_port]
- self.client_bi_dir_nsock_timeout = 120
+ self.client_bi_dir_nsock_timeout = 20
self.client_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
"-I", "2",
self.server_addr,
def tearDown(self):
self.cut_thru_tear_down()
- super(VCLCutThruTestCase, self).tearDown()
+ super(LDPCutThruTestCase, self).tearDown()
def test_ldp_cut_thru_echo(self):
""" run LDP cut thru echo test """
"sock_test_client",
self.client_bi_dir_nsock_test_args)
+
+class VCLCutThruTestCase(VCLTestCase):
+ """ VCL Cut Thru Tests """
+
+ def setUp(self):
+ super(VCLCutThruTestCase, self).setUp()
+
+ self.cut_thru_setup()
+ self.client_echo_test_args = ["-E", self.echo_phrase, "-X",
+ self.server_addr, self.server_port]
+
+ self.client_uni_dir_nsock_timeout = 20
+ self.client_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",
+ "-I", "2",
+ self.server_addr,
+ self.server_port]
+ self.client_bi_dir_nsock_timeout = 20
+ self.client_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
+ "-I", "2",
+ self.server_addr,
+ self.server_port]
+
+ def tearDown(self):
+ self.cut_thru_tear_down()
+
+ super(VCLCutThruTestCase, self).tearDown()
+
def test_vcl_cut_thru_echo(self):
""" run VCL cut thru echo test """
self.thru_host_stack_setup()
if self.vppDebug:
- self.client_bi_dir_nsock_timeout = 120
+ self.client_bi_dir_nsock_timeout = 20
self.client_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
"-I", "2",
self.loop0.local_ip4,
self.server_port]
else:
- self.client_bi_dir_nsock_timeout = 90
+ self.client_bi_dir_nsock_timeout = 20
self.client_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
"-I", "2",
self.loop0.local_ip4,
self.thru_host_stack_setup()
if self.vppDebug:
- self.client_bi_dir_nsock_timeout = 120
+ self.client_bi_dir_nsock_timeout = 20
self.client_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
# OUCH! Host Stack Bug?
# "-I", "2",
self.loop0.local_ip4,
self.server_port]
else:
- self.client_bi_dir_nsock_timeout = 60
+ self.client_bi_dir_nsock_timeout = 20
self.client_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
# OUCH! Host Stack Bug?
# "-I", "2",
self.thru_host_stack_setup()
if self.vppDebug:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "2"
else:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "5"
self.client_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",
self.thru_host_stack_setup()
if self.vppDebug:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "2"
else:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "5"
self.client_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",
"iperf3", self.client_iperf3_args)
-class VCLIpv6CutThruTestCase(VCLTestCase):
- """ VCL IPv6 Cut Thru Tests """
+class LDPIpv6CutThruTestCase(VCLTestCase):
+ """ LDP IPv6 Cut Thru Tests """
def setUp(self):
- super(VCLIpv6CutThruTestCase, self).setUp()
+ super(LDPIpv6CutThruTestCase, self).setUp()
self.cut_thru_setup()
self.client_iperf3_timeout = 20
- self.client_uni_dir_nsock_timeout = 60
- self.client_bi_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
+ self.client_bi_dir_nsock_timeout = 20
self.client_ipv6_echo_test_args = ["-6", "-E", self.echo_phrase, "-X",
self.server_ipv6_addr,
self.server_port]
def tearDown(self):
self.cut_thru_tear_down()
- super(VCLIpv6CutThruTestCase, self).tearDown()
+ super(LDPIpv6CutThruTestCase, self).tearDown()
def test_ldp_ipv6_cut_thru_echo(self):
""" run LDP IPv6 cut thru echo test """
"sock_test_client",
self.client_ipv6_bi_dir_nsock_test_args)
+
+class VCLIpv6CutThruTestCase(VCLTestCase):
+ """ VCL IPv6 Cut Thru Tests """
+
+ def setUp(self):
+ super(VCLIpv6CutThruTestCase, self).setUp()
+
+ self.cut_thru_setup()
+ self.client_uni_dir_nsock_timeout = 20
+ self.client_bi_dir_nsock_timeout = 20
+ self.client_ipv6_echo_test_args = ["-6", "-E", self.echo_phrase, "-X",
+ self.server_ipv6_addr,
+ self.server_port]
+ self.client_ipv6_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",
+ "-6",
+ "-I", "2",
+ self.server_ipv6_addr,
+ self.server_port]
+ self.client_ipv6_bi_dir_nsock_test_args = ["-N", "1000", "-B", "-X",
+ "-6",
+ "-I", "2",
+ self.server_ipv6_addr,
+ self.server_port]
+
+ def tearDown(self):
+ self.cut_thru_tear_down()
+
+ super(VCLIpv6CutThruTestCase, self).tearDown()
+
def test_vcl_ipv6_cut_thru_echo(self):
""" run VCL IPv6 cut thru echo test """
self.thru_host_stack_ipv6_setup()
if self.vppDebug:
- self.client_bi_dir_nsock_timeout = 120
+ self.client_bi_dir_nsock_timeout = 20
self.client_ipv6_bi_dir_nsock_test_args = ["-N", "1000",
"-B", "-X", "-6",
"-I", "2",
self.loop0.local_ip6,
self.server_port]
else:
- self.client_bi_dir_nsock_timeout = 90
+ self.client_bi_dir_nsock_timeout = 20
self.client_ipv6_bi_dir_nsock_test_args = ["-N", "1000",
"-B", "-X", "-6",
"-I", "2",
self.thru_host_stack_ipv6_setup()
if self.vppDebug:
- self.client_bi_dir_nsock_timeout = 120
+ self.client_bi_dir_nsock_timeout = 20
self.client_ipv6_bi_dir_nsock_test_args = ["-N", "1000",
"-B", "-X", "-6",
# OUCH! Host Stack Bug?
self.loop0.local_ip6,
self.server_port]
else:
- self.client_bi_dir_nsock_timeout = 60
+ self.client_bi_dir_nsock_timeout = 20
self.client_ipv6_bi_dir_nsock_test_args = ["-N", "1000",
"-B", "-X", "-6",
# OUCH! Host Stack Bug?
self.thru_host_stack_ipv6_setup()
if self.vppDebug:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "2"
else:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "5"
self.client_ipv6_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",
self.thru_host_stack_ipv6_setup()
if self.vppDebug:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "2"
else:
- self.client_uni_dir_nsock_timeout = 120
+ self.client_uni_dir_nsock_timeout = 20
self.numSockets = "5"
self.client_ipv6_uni_dir_nsock_test_args = ["-N", "1000", "-U", "-X",