Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 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
3 changes: 2 additions & 1 deletion tests/test_regular_scan_hash.py
Original file line number Diff line number Diff line change
Expand Up @@ -1512,7 +1512,8 @@ def mock_hash(path: str, *, deadline: float | None = None) -> str:
# files_scanned should include both files
assert result.files_scanned == 2

def test_hash_generation_performance(self, tmp_path):
@pytest.mark.performance
Comment thread
mldangelo-oai marked this conversation as resolved.
Resolved
def test_hash_generation_performance(self, tmp_path: Path) -> None:
"""Test that hash generation doesn't significantly impact performance."""
import time

Expand Down
8 changes: 8 additions & 0 deletions tests/test_xdist_status.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,14 @@ def test_nightly_runs_unsharded_performance_and_rust_once_and_fails_closed() ->
assert all("continue-on-error" not in step for step in job["steps"])


def test_wall_clock_hash_generation_uses_dedicated_performance_lane() -> None:
from tests.test_regular_scan_hash import TestHashGenerationEdgeCases

marks = getattr(TestHashGenerationEdgeCases.test_hash_generation_performance, "pytestmark", ())

assert any(mark.name == "performance" for mark in marks)


def test_nodeid_sharding_rejects_non_positive_count() -> None:
root_conftest = _load_root_conftest()

Expand Down