Skip to content
Closed
Show file tree
Hide file tree
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
6 changes: 5 additions & 1 deletion tests/unit/memory/test_attack_analytics.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,12 @@ def make_result(
)


# Only a guard against hangs: loaded CI runners have taken over 30s for these queries.
_QUERY_BUDGET_SECONDS = 120


def control() -> QueryControl:
return QueryControl(deadline=time.monotonic() + 10)
return QueryControl(deadline=time.monotonic() + _QUERY_BUDGET_SECONDS)


def predicate(*, name: str, values: list[str | None], **options: Any) -> dict[str, Any]:
Expand Down
6 changes: 5 additions & 1 deletion tests/unit/memory/test_attack_analytics_eval_identity.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,12 @@ def _result(*, index: int, target: TargetIdentifier, outcome: AttackOutcome, ope
)


# Only a guard against hangs: loaded CI runners have taken over 30s for these queries.
_QUERY_BUDGET_SECONDS = 120


def _control() -> QueryControl:
return QueryControl(deadline=time.monotonic() + 20)
return QueryControl(deadline=time.monotonic() + _QUERY_BUDGET_SECONDS)


def test_target_evaluation_v1_is_frozen_to_the_current_marker_rules() -> None:
Expand Down
6 changes: 5 additions & 1 deletion tests/unit/memory/test_attack_analytics_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,12 @@ def _result(
)


# Only a guard against hangs: loaded CI runners have taken over 30s for these queries.
_QUERY_BUDGET_SECONDS = 120


def _control() -> QueryControl:
return QueryControl(deadline=time.monotonic() + 30)
return QueryControl(deadline=time.monotonic() + _QUERY_BUDGET_SECONDS)


def _filters(*, values: list[tuple[AttackAnalyticsDimension, str]]) -> AttackAnalyticsFilters:
Expand Down