refactor(tests): Add strict type hints to fourth batch of test files

This commit is contained in:
2026-02-28 19:20:41 -05:00
parent e8513d563b
commit ee2d6f4234
9 changed files with 34 additions and 27 deletions

View File

@@ -1,3 +1,4 @@
from typing import Tuple
import os
import shutil
import pytest
@@ -7,7 +8,7 @@ from log_registry import LogRegistry
from log_pruner import LogPruner
@pytest.fixture
def pruner_setup(tmp_path):
def pruner_setup(tmp_path: Path) -> Tuple[LogPruner, LogRegistry, Path]:
logs_dir = tmp_path / "logs"
logs_dir.mkdir()
registry_path = logs_dir / "log_registry.toml"
@@ -15,7 +16,7 @@ def pruner_setup(tmp_path):
pruner = LogPruner(registry, str(logs_dir))
return pruner, registry, logs_dir
def test_prune_old_insignificant_logs(pruner_setup):
def test_prune_old_insignificant_logs(pruner_setup: Tuple[LogPruner, LogRegistry, Path]) -> None:
pruner, registry, logs_dir = pruner_setup
# 1. Old and small (insignificant) -> should be pruned
session_id_old_small = "old_small"