Skip to content

Commit

Permalink
feat: include abuseControl timeout to initial VD tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Rebits committed Jun 17, 2024
1 parent 3cd69e3 commit 053b78c
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,11 @@
from wazuh_testing.end_to_end.waiters import wait_until_vd_is_updated
from wazuh_testing.tools.system import HostManager


pytestmark = [pytest.mark.e2e, pytest.mark.vulnerability_detector, pytest.mark.tier0]

# Wazuh Indexer abuseControl timeout set to 30 minutes (1800 seconds)
MINIMUM_TIMEOUT_RESCAN = 1800

AGENTS_SCANNED_FIRST_SCAN = []
FIRST_SCAN_TIME = None
Expand Down Expand Up @@ -318,7 +321,10 @@ def test_first_syscollector_scan(
)

logging.critical("Waiting until agent all agents have been scanned.")
time.sleep(TIMEOUT_PER_AGENT_VULNERABILITY_FIRST_SCAN * len(AGENTS_SCANNED_FIRST_SCAN))

time_to_wait = max(TIMEOUT_PER_AGENT_VULNERABILITY_FIRST_SCAN * len(AGENTS_SCANNED_FIRST_SCAN),
MINIMUM_TIMEOUT_RESCAN)
time.sleep(time_to_wait)

logging.critical("Checking vulnerabilities in the index")
vuln_by_agent_index = get_vulnerabilities_from_states_by_agent(
Expand Down

0 comments on commit 053b78c

Please sign in to comment.