Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dualtor] Fix snmp/* tests failure on fixture teardown #15529

Merged
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
9 changes: 5 additions & 4 deletions tests/snmp/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,15 @@ def setup_check_snmp_ready(duthosts, localhost):
if 'LOCATION' not in snmp_location_redis_vals:
duthost.shell(f'sudo config snmp location add {yaml_snmp_location}') # set snmp cli

yield
yield

for duthost in duthosts:
# rollback configuration
rollback(duthost, SETUP_ENV_CP)

# remove snmp files downloaded
local_command = "find ./snmp/ -type f -name 'snmp.yml' -exec rm -f {} +"
localhost.shell(local_command)
# remove snmp files downloaded
local_command = "find ./snmp/ -type f -name 'snmp.yml' -exec rm -f {} +"
localhost.shell(local_command)


def extract_redis_keys(item):
Expand Down
Loading