diff options
author | 2016-12-12 18:11:49 +0200 | |
---|---|---|
committer | 2016-12-12 18:11:49 +0200 | |
commit | 6c31c0534acf57fc3e0e26fe964bbc67d9d7d63c (patch) | |
tree | f10ef26c46ed924db11dc18e0d4780a9e1766873 /scripts/automation | |
parent | 91cccaebfee5d9bcb8d33a52522a28307748482f (diff) |
Added VIC tests + VIC small fix + fail tests if latency packets fail
Signed-off-by: Ido Barnea <ibarnea@cisco.com>
Diffstat (limited to 'scripts/automation')
-rw-r--r-- | scripts/automation/regression/setups/trex11/benchmark.yaml | 13 | ||||
-rwxr-xr-x | scripts/automation/regression/stateful_tests/trex_general_test.py | 13 |
2 files changed, 24 insertions, 2 deletions
diff --git a/scripts/automation/regression/setups/trex11/benchmark.yaml b/scripts/automation/regression/setups/trex11/benchmark.yaml index a4969d2d..5ebcdd55 100644 --- a/scripts/automation/regression/setups/trex11/benchmark.yaml +++ b/scripts/automation/regression/setups/trex11/benchmark.yaml @@ -40,6 +40,19 @@ test_rx_check_http: &rx_http rx_sample_rate : 128 bw_per_core : 49.464 +test_rx_check_http_ipv6: + << : *rx_http + bw_per_core : 49.237 + +test_rx_check_sfr: &rx_sfr + multiplier : 8 + cores : 1 + rx_sample_rate : 128 + bw_per_core : 20.9 + +test_rx_check_sfr_ipv6: + << : *rx_sfr + bw_per_core : 23.9 ### stateless ### diff --git a/scripts/automation/regression/stateful_tests/trex_general_test.py b/scripts/automation/regression/stateful_tests/trex_general_test.py index 1843af00..5c1649e7 100755 --- a/scripts/automation/regression/stateful_tests/trex_general_test.py +++ b/scripts/automation/regression/stateful_tests/trex_general_test.py @@ -257,7 +257,7 @@ class CTRexGeneral_Test(unittest.TestCase): allowed_latency = 1000 if max(trex_res.get_max_latency().values()) > allowed_latency: self.fail('LatencyError: Maximal latency exceeds %s (usec)' % allowed_latency) - + # check that avg latency does not exceed 1 msec if self.is_VM: allowed_latency = 9999999 @@ -266,6 +266,15 @@ class CTRexGeneral_Test(unittest.TestCase): if max(trex_res.get_avg_latency().values()) > allowed_latency: self.fail('LatencyError: Average latency exceeds %s (usec)' % allowed_latency) + ports_names = trex_res.get_last_value('trex-latecny-v2.data', 'port\-\d+') + if not ports_names: + raise AbnormalResultError('Could not find ports info in TRex results, path: trex-latecny-v2.data.port-*') + for port_name in ports_names: + path = 'trex-latecny-v2.data.%s.hist.cont' % port_name + lat_count = trex_res.get_last_value(path) + if lat_count == 0: + self.fail('LatencyError: Number of latency packets received on %s is 0' % port_name) + if not self.is_loopback: # check router number of drops --> deliberately masked- need to be figured out!!!!! pkt_drop_stats = self.router.get_drop_stats() @@ -359,7 +368,7 @@ class CTRexGeneral_Test(unittest.TestCase): print("Can't get TRex log:", e) if len(self.fail_reasons): sys.stdout.flush() - raise Exception('The test is failed, reasons:\n%s' % '\n'.join(self.fail_reasons)) + raise Exception('Test failed. Reasons:\n%s' % '\n'.join(self.fail_reasons)) sys.stdout.flush() def check_for_trex_crash(self): |