Skip to content
Merged
Changes from 1 commit
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
4 changes: 3 additions & 1 deletion tests/generic_config_updater/test_pfcwd_interval.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@ def get_detection_restoration_times(duthost):
Args:
duthost: DUT host object
"""


duthost.shell('config pfcwd start --action drop all 400 --restoration-time 400', module_ignore_errors=True)
time.sleep(15)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

15

Why 15 seconds? I see other code sleep 5 seconds. Still is it possible not to use magic number at all? For example, sleep until we find a signal that the config take effect.
@neethajohn

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do not need 15s. we can check immediately

pfcwd_config = duthost.shell("show pfcwd config")
pytest_assert(not pfcwd_config['rc'], "Unable to read pfcwd config")

Expand Down