Timeout before getting logs

Elvira noticed more occurrences where logs aren't fully written and
partially fetched, so this fix adds generic wait time before any log
fetching.
Removed existing timeout to avoid double timeout done.

Change-Id: I54a304c22108f79fa425bdb1b057536e00c072d2
This commit is contained in:
Maor Blaustein 2025-03-05 17:53:42 +02:00
parent 8c3bb22f49
commit c7c5a02eb2

View File

@ -213,7 +213,8 @@ class BaseSecGroupLoggingTest(
hypervisor_ssh.host, _track_value)
else:
# tracks B value, after test traffic sent to be logged
# (extracts logs from file right away, to avoid race conditions).
# (wait time for logging to be done fully).
time.sleep(5)
cmd_outputs = hypervisor_ssh.exec_command(
"sudo grep ovn_pinctrl0 {0}".format(self.SG_LOG_FILE),
timeout=120).splitlines()
@ -674,7 +675,6 @@ class BaseSecGroupLoggingTest(
ping_amount = 10
self.check_remote_connectivity(
vm_a['ssh_client'], vm_b_internal_ip, ping_count=ping_amount)
time.sleep(5)
self.retrieve_tracked_log(vm_a['hv_ssh_client'])
if not same_compute:
self.retrieve_tracked_log(vm_b['hv_ssh_client'])