diff options
Diffstat (limited to 'scripts/automation/regression/stateful_tests/trex_nbar_test.py')
-rwxr-xr-x | scripts/automation/regression/stateful_tests/trex_nbar_test.py | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/scripts/automation/regression/stateful_tests/trex_nbar_test.py b/scripts/automation/regression/stateful_tests/trex_nbar_test.py index 6611ac96..a98da9ac 100755 --- a/scripts/automation/regression/stateful_tests/trex_nbar_test.py +++ b/scripts/automation/regression/stateful_tests/trex_nbar_test.py @@ -5,18 +5,7 @@ from interfaces_e import IFType from nose.tools import nottest from misc_methods import print_r -class CTRexNbar_Test(CTRexGeneral_Test): - """This class defines the NBAR testcase of the TRex traffic generator""" - def __init__(self, *args, **kwargs): - super(CTRexNbar_Test, self).__init__(*args, **kwargs) - self.unsupported_modes = ['loopback'] # obviously no NBar in loopback - - def setUp(self): - super(CTRexNbar_Test, self).setUp() # launch super test class setUp process -# self.router.kill_nbar_flows() - self.router.clear_cft_counters() - self.router.clear_nbar_stats() - +class CTRexNbarBase(CTRexGeneral_Test): def match_classification (self): nbar_benchmark = self.get_benchmark_param("nbar_classification") test_classification = self.router.get_nbar_stats() @@ -52,6 +41,17 @@ class CTRexNbar_Test(CTRexGeneral_Test): if missmatchFlag: self.fail(missmatchMsg) +class CTRexNbar_Test(CTRexNbarBase): + """This class defines the NBAR testcase of the TRex traffic generator""" + def __init__(self, *args, **kwargs): + super(CTRexNbar_Test, self).__init__(*args, **kwargs) + self.unsupported_modes = ['loopback'] # obviously no NBar in loopback + + def setUp(self): + super(CTRexNbar_Test, self).setUp() # launch super test class setUp process +# self.router.kill_nbar_flows() + self.router.clear_cft_counters() + self.router.clear_nbar_stats() def test_nbar_simple(self): # test initializtion |