diff options
author | pmikus <peter.mikus@protonmail.ch> | 2023-10-26 12:34:10 +0000 |
---|---|---|
committer | Peter Mikus <peter.mikus@protonmail.ch> | 2023-11-03 13:26:43 +0000 |
commit | 89cff3cb43f10355022115396a65f491bf3f8404 (patch) | |
tree | 2340cf6ea44670c9fadbc7389c2b248952bd937a /resources/libraries/python/TrafficGenerator.py | |
parent | 30ac3eb3d8e508f80445936a218deaa3c9dc0e84 (diff) |
feat(tests): 6p3nic ip4 testsoper-231106
Signed-off-by: Peter Mikus <peter.mikus@protonmail.ch>
Change-Id: I69ee305b25b9e05d2305cb82aba71ef6418780ab
Diffstat (limited to 'resources/libraries/python/TrafficGenerator.py')
-rw-r--r-- | resources/libraries/python/TrafficGenerator.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/resources/libraries/python/TrafficGenerator.py b/resources/libraries/python/TrafficGenerator.py index 7c6c859448..936cb3a06d 100644 --- a/resources/libraries/python/TrafficGenerator.py +++ b/resources/libraries/python/TrafficGenerator.py @@ -281,13 +281,13 @@ class TrafficGenerator(AbstractMeasurer): return stdout.strip() return "none" - def initialize_traffic_generator(self, osi_layer, parallel_links=1): + def initialize_traffic_generator(self, osi_layer, pfs=2): """TG initialization. :param osi_layer: 'L2', 'L3' or 'L7' - OSI Layer testing type. - :param parallel_links: Number of parallel links to configure. + :param pfs: Number of physical interfaces to configure. :type osi_layer: str - :type parallel_links: int + :type pfs: int :raises ValueError: If OSI layer is unknown. """ if osi_layer not in ("L2", "L3", "L7"): @@ -301,7 +301,7 @@ class TrafficGenerator(AbstractMeasurer): trex_topology = list() self._mode = TrexMode.ASTF if osi_layer == "L7" else TrexMode.STL - for link in range(1, parallel_links*2, 2): + for link in range(1, pfs, 2): tg_if1_adj_addr = topology[f"TG_pf{link+1}_mac"][0] tg_if2_adj_addr = topology[f"TG_pf{link}_mac"][0] if osi_layer in ("L3", "L7") and "DUT1" in topology.keys(): |