testsAndMisc/python_pkg/steam_backlog_enforcer/tests
Krzysztof kuhy Rudnicki 63354a9e2e steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data
Four bugs fixed:
- HLTB search returned 0 results for ~87 games with special chars (™, ®, &,
  standalone -, (Legacy), RHCP, etc.) — add _sanitize_search_name() and
  extend _build_search_variants() with Steam-suffix and edition stripping
- fetch_hltb_detail_missing returned immediately because `app_id not in rush`
  was always False (all keys present with -1) — fix to `rush.get(id,-1) <= 0`
- save_hltb_cache overwrote rush/leisure on confidence-only partial saves —
  now reads existing cache and preserves data when extras dicts are empty
- _filter_qualifying_games excluded 57 games with stale snapshot hours (-1)
  even though HLTB hours cache had valid data — add cache fallback

Result: stats shows Rush 64,670h / Leisure 136,807h / Worst 228,594h for
all 785 qualifying games with full rush+leisure detail.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 07:02:48 +02:00
..
__init__.py test: achieve 100% branch coverage across all python_pkg packages 2026-03-21 17:51:36 +01:00
conftest.py feat(steam_backlog_enforcer): harden whitelist against circumvention 2026-05-17 20:44:05 +02:00
test_cmd_done_part2.py steam_backlog_enforcer: only prompt next pick after game is finished 2026-05-23 21:19:44 +02:00
test_config.py steam_backlog_enforcer: only prompt next pick after game is finished 2026-05-23 21:19:44 +02:00
test_enforce_loop_part2.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_enforce_loop.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_enforcer.py feat(steam_backlog_enforcer): harden whitelist against circumvention 2026-05-17 20:44:05 +02:00
test_game_install_part2.py Reduce per-file-ignores by fixing lint violations across codebase 2026-03-25 18:58:05 +01:00
test_game_install_part3.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_game_install.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_hltb_detail.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_hltb_part2.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_hltb_part3.py test: achieve 100% branch coverage across all python_pkg packages 2026-03-21 17:51:36 +01:00
test_hltb_search_part2.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_hltb_search.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_hltb.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_library_hider_part2.py chore: optimize pre-commit, remove tracked binaries, fix lint issues 2026-04-10 18:48:37 +02:00
test_library_hider.py chore: optimize pre-commit, remove tracked binaries, fix lint issues 2026-04-10 18:48:37 +02:00
test_main_part2.py steam_backlog_enforcer: only prompt next pick after game is finished 2026-05-23 21:19:44 +02:00
test_main_part3.py steam_backlog_enforcer: only prompt next pick after game is finished 2026-05-23 21:19:44 +02:00
test_main.py feat(steam_backlog_enforcer): harden whitelist against circumvention 2026-05-17 20:44:05 +02:00
test_polls_tracking_part2.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_polls_tracking.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_protondb.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_scanning_part2.py test: achieve 100% branch coverage across all python_pkg packages 2026-03-21 17:51:36 +01:00
test_scanning_part3.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_scanning_part4.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_scanning.py Split modules, fix tests, fix pre-commit batching 2026-05-22 22:48:28 +02:00
test_stats.py steam_backlog_enforcer: fix stats command — show real Rush/Leisure/Worst data 2026-05-28 07:02:48 +02:00
test_steam_api.py feat(steam_backlog_enforcer): harden whitelist against circumvention 2026-05-17 20:44:05 +02:00
test_store_blocker_part2.py Reduce per-file-ignores by fixing lint violations across codebase 2026-03-25 18:58:05 +01:00
test_store_blocker.py Reduce per-file-ignores by fixing lint violations across codebase 2026-03-25 18:58:05 +01:00
test_whitelist.py feat(steam_backlog_enforcer): harden whitelist against circumvention 2026-05-17 20:44:05 +02:00