diff --git a/tests/test_categorizer.py b/tests/test_categorizer.py index 7b10b9b5..f15c1ea6 100644 --- a/tests/test_categorizer.py +++ b/tests/test_categorizer.py @@ -36,3 +36,24 @@ def test_auto_classify_default_to_unit(tmp_path: Path) -> None: p = _write(tmp_path, "test_command_palette.py", "def test_x(): pass\n") r = auto_classify(p) assert r.fixture_class == FixtureClass.UNIT + +def test_subsystem_inference_known_prefix(tmp_path: Path) -> None: + p = _write(tmp_path, "test_mcp_client_foo.py", "def test_x(): pass\n") + r = auto_classify(p) + assert "mcp" in r.subsystems + +def test_speed_inference_from_durations_fast(tmp_path: Path) -> None: + p = _write(tmp_path, "test_x.py", "def test_x(): pass\n") + durations = {f"{p.name}::test_x": 0.05} + r = auto_classify(p, durations=durations) + assert r.speed == Speed.FAST + +def test_speed_default_medium_without_durations(tmp_path: Path) -> None: + p = _write(tmp_path, "test_x.py", "def test_x(): pass\n") + r = auto_classify(p) + assert r.speed == Speed.MEDIUM + +def test_batch_group_inference_gui_subsystem(tmp_path: Path) -> None: + p = _write(tmp_path, "test_gui_layout_foo.py", "def test_x(): pass\n") + r = auto_classify(p) + assert r.batch_group == "gui"