testsAndMisc/scripts
Krzysztof kuhy Rudnicki c23eb4d1a9 perf(pre-commit): batch+parallelize pytest on commit; kill 15s sleeps in steam_backlog_enforcer tests
- meta/.pre-commit-config.yaml: move pytest-coverage hook to pre-commit stage
- scripts/pytest_changed_packages.py: single batched pytest -n auto invocation
  with one --cov flag per affected python_pkg subpackage, wrapped in
  systemd-run --user --scope -p MemoryMax=4G -p MemorySwapMax=0 when available
- python_pkg/steam_backlog_enforcer/tests/conftest.py: new autouse
  _no_real_sleep fixture patches time.sleep across game_install /
  library_hider / steam_api / _enforce_loop. Removes 3x 15s real sleeps
  in TestFinalizeCompletion that fired through _ensure_steam_running

steam_backlog_enforcer test wall time: 33.97s -> 5.61s (xdist, no-cov)
5-package batched run: 732 tests in 1.37s @ 668% CPU
Coverage stays at 100% on all affected packages.

Evidence: docs/superpowers/evidence/pre-commit-pytest-batch-2026-05-14.json
2026-05-14 21:52:52 +02:00
..
run_all feat(phone-focus): add recovery workflow, automation scripts, and docs 2026-05-01 19:07:27 +02:00
check_agent_contract.sh chore(agent): add governance checks and artifact workflow scaffolding 2026-05-07 22:03:43 +02:00
check_ai_evidence.sh chore(agent): add governance checks and artifact workflow scaffolding 2026-05-07 22:03:43 +02:00
check_append_only_sessions.sh chore(agent): add governance checks and artifact workflow scaffolding 2026-05-07 22:03:43 +02:00
check_no_binaries.sh chore: optimize pre-commit, remove tracked binaries, fix lint issues 2026-04-10 18:48:37 +02:00
check_no_secrets.sh fix: bluetooth optimze arch desktop phone foucs mode and no secres 2026-03-02 19:13:22 +01:00
check_polling_antipatterns.sh feat: Add shell script quality enforcement and polling optimization guidelines 2026-05-03 21:42:49 +02:00
check_python_location.sh chore: archive 41 unmaintained directories to testsAndMisc-archive 2026-05-14 20:21:05 +02:00
disk_cleanup_check.sh chore: optimize pre-commit, remove tracked binaries, fix lint issues 2026-04-10 18:48:37 +02:00
init_agent_artifacts.sh chore(agent): add governance checks and artifact workflow scaffolding 2026-05-07 22:03:43 +02:00
makepkg-manual-dlagent.sh fix: bluetooth optimze arch desktop phone foucs mode and no secres 2026-03-02 19:13:22 +01:00
optimize_vscode.py Add VS Code auto-optimizer and selective pytest pre-commit hook 2026-03-25 21:56:37 +01:00
pytest_changed_packages.py perf(pre-commit): batch+parallelize pytest on commit; kill 15s sleeps in steam_backlog_enforcer tests 2026-05-14 21:52:52 +02:00
run_prettier_capped.sh perf(pre-commit): run prettier in its own systemd-run scope 2026-05-14 21:12:32 +02:00