Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 19 additions & 19 deletions tests/qos/qos_sai_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
from tests.common.helpers.assertions import pytest_assert, pytest_require
from tests.common.mellanox_data import is_mellanox_device as isMellanoxDevice
from tests.common.cisco_data import is_cisco_device
# from tests.common.dualtor.dual_tor_utils import upper_tor_host, lower_tor_host, dualtor_ports # noqa F401
from tests.common.dualtor.dual_tor_utils import upper_tor_host, lower_tor_host, dualtor_ports # noqa F401
from tests.common.dualtor.mux_simulator_control \
import toggle_all_simulator_ports, get_mux_status, check_mux_status, validate_check_result # noqa F401
from tests.common.dualtor.constants import UPPER_TOR, LOWER_TOR # noqa F401
Expand Down Expand Up @@ -750,7 +750,7 @@ def dutConfig(
@pytest.fixture(scope='class')
def ssh_tunnel_to_syncd_rpc(
self, duthosts, enum_rand_one_per_hwsku_frontend_hostname, enum_frontend_asic_index,
swapSyncd, tbinfo, lower_tor_host
swapSyncd, tbinfo, lower_tor_host # noqa: F811
):
if 'dualtor' in tbinfo['topo']['name']:
duthost = lower_tor_host
Expand All @@ -766,7 +766,7 @@ def ssh_tunnel_to_syncd_rpc(
@pytest.fixture(scope='class')
def updateIptables(
self, duthosts, enum_rand_one_per_hwsku_frontend_hostname, enum_frontend_asic_index, swapSyncd, tbinfo,
lower_tor_host
lower_tor_host # noqa: F811
):
"""
Update iptables on DUT host with drop rule for BGP SYNC packets
Expand Down Expand Up @@ -821,7 +821,7 @@ def stopServices(

dut_asic = duthost.asic_instance(enum_frontend_asic_index)

def updateDockerService(host, docker="", action="", service=""):
def updateDockerService(host, docker="", action="", service=""): # noqa: F811
"""
Helper function to update docker services

Expand Down Expand Up @@ -1017,7 +1017,7 @@ def dutQosConfig(
self, duthosts, enum_frontend_asic_index, enum_rand_one_per_hwsku_frontend_hostname,
dutConfig, ingressLosslessProfile, ingressLossyProfile,
egressLosslessProfile, egressLossyProfile, sharedHeadroomPoolSize,
tbinfo, lower_tor_host
tbinfo, lower_tor_host # noqa: F811
):
"""
Prepares DUT host QoS configuration
Expand Down Expand Up @@ -1195,7 +1195,7 @@ def __deleteTmpSwitchConfig(self, duthost):
duthost.file(path=file["path"], state="absent")

@pytest.fixture(scope='class', autouse=True)
def handleFdbAging(self, tbinfo, duthosts, lower_tor_host, enum_rand_one_per_hwsku_frontend_hostname):
def handleFdbAging(self, tbinfo, duthosts, lower_tor_host, enum_rand_one_per_hwsku_frontend_hostname): # noqa: F811
"""
Disable FDB aging and reenable at the end of tests

Expand Down Expand Up @@ -1240,7 +1240,7 @@ def handleFdbAging(self, tbinfo, duthosts, lower_tor_host, enum_rand_one_per_hws
@pytest.fixture(scope='class', autouse=True)
def populateArpEntries(
self, duthosts, enum_frontend_asic_index, enum_rand_one_per_hwsku_frontend_hostname,
ptfhost, dutTestParams, dutConfig, releaseAllPorts, handleFdbAging, tbinfo, lower_tor_host
ptfhost, dutTestParams, dutConfig, releaseAllPorts, handleFdbAging, tbinfo, lower_tor_host # noqa: F811
):
"""
Update ARP entries of QoS SAI test ports
Expand Down Expand Up @@ -1289,7 +1289,8 @@ def populateArpEntries(
)

@pytest.fixture(scope='class', autouse=True)
def dut_disable_ipv6(self, duthosts, enum_rand_one_per_hwsku_frontend_hostname, tbinfo, lower_tor_host):
def dut_disable_ipv6(
self, duthosts, enum_rand_one_per_hwsku_frontend_hostname, tbinfo, lower_tor_host): # noqa: F811
if 'dualtor' in tbinfo['topo']['name']:
duthost = lower_tor_host
else:
Expand All @@ -1303,7 +1304,7 @@ def dut_disable_ipv6(self, duthosts, enum_rand_one_per_hwsku_frontend_hostname,
@pytest.fixture(scope='class', autouse=True)
def sharedHeadroomPoolSize(
self, request, duthosts, enum_frontend_asic_index,
enum_rand_one_per_hwsku_frontend_hostname, tbinfo, lower_tor_host
enum_rand_one_per_hwsku_frontend_hostname, tbinfo, lower_tor_host # noqa: F811
):
"""
Retreives shared headroom pool size
Expand All @@ -1329,7 +1330,7 @@ def sharedHeadroomPoolSize(
@pytest.fixture(scope='class', autouse=True)
def ingressLosslessProfile(
self, request, duthosts, enum_frontend_asic_index,
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host, dualtor_ports
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host, dualtor_ports # noqa: F811
):
"""
Retreives ingress lossless profile
Expand Down Expand Up @@ -1370,7 +1371,7 @@ def ingressLosslessProfile(
@pytest.fixture(scope='class', autouse=True)
def ingressLossyProfile(
self, request, duthosts, enum_frontend_asic_index,
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host # noqa: F811
):
"""
Retreives ingress lossy profile
Expand Down Expand Up @@ -1403,7 +1404,7 @@ def ingressLossyProfile(
@pytest.fixture(scope='class', autouse=True)
def egressLosslessProfile(
self, request, duthosts, enum_frontend_asic_index,
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host, dualtor_ports
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host, dualtor_ports # noqa: F811
):
"""
Retreives egress lossless profile
Expand Down Expand Up @@ -1444,7 +1445,7 @@ def egressLosslessProfile(
@pytest.fixture(scope='class', autouse=True)
def egressLossyProfile(
self, request, duthosts, enum_frontend_asic_index,
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host, dualtor_ports
enum_rand_one_per_hwsku_frontend_hostname, dutConfig, tbinfo, lower_tor_host, dualtor_ports # noqa: F811
):
"""
Retreives egress lossy profile
Expand Down Expand Up @@ -1485,7 +1486,7 @@ def egressLossyProfile(
@pytest.fixture(scope='class')
def losslessSchedProfile(
self, duthosts, enum_frontend_asic_index, enum_rand_one_per_hwsku_frontend_hostname,
dutConfig, tbinfo, lower_tor_host
dutConfig, tbinfo, lower_tor_host # noqa: F811
):
"""
Retreives lossless scheduler profile
Expand All @@ -1512,7 +1513,7 @@ def losslessSchedProfile(
@pytest.fixture(scope='class')
def lossySchedProfile(
self, duthosts, enum_frontend_asic_index, enum_rand_one_per_hwsku_frontend_hostname,
dutConfig, tbinfo, lower_tor_host
dutConfig, tbinfo, lower_tor_host # noqa: F811
):
"""
Retreives lossy scheduler profile
Expand All @@ -1539,7 +1540,7 @@ def lossySchedProfile(
@pytest.fixture
def updateSchedProfile(
self, duthosts, enum_rand_one_per_hwsku_frontend_hostname, enum_frontend_asic_index,
dutQosConfig, losslessSchedProfile, lossySchedProfile, tbinfo, lower_tor_host
dutQosConfig, losslessSchedProfile, lossySchedProfile, tbinfo, lower_tor_host # noqa: F811
):
"""
Updates lossless/lossy scheduler profiles
Expand Down Expand Up @@ -1611,9 +1612,8 @@ def updateRedisSchedParam(schedParam):
updateRedisSchedParam(schedParam)

@pytest.fixture
def resetWatermark(
self, duthosts, enum_frontend_asic_index, enum_rand_one_per_hwsku_frontend_hostname, tbinfo, lower_tor_host
):
def resetWatermark(self, duthosts, enum_frontend_asic_index,
enum_rand_one_per_hwsku_frontend_hostname, tbinfo, lower_tor_host): # noqa: F811
"""
Reset queue watermark

Expand Down