Skip to content

Steam connector tests (16 tests) — _distill_profile, connect 503, analyze endpoints - #47

Open
brooksRoley wants to merge 1 commit into
mainfrom
claude/em-steam-connector-tests
Open

Steam connector tests (16 tests) — _distill_profile, connect 503, analyze endpoints#47
brooksRoley wants to merge 1 commit into
mainfrom
claude/em-steam-connector-tests

Conversation

@brooksRoley

Copy link
Copy Markdown
Owner

What

Adds server/tests/test_steam_connector.py — 16 tests covering the Steam connector's testable surface using the existing FakeConn pattern.

Steam was the last connector with zero server-side tests. With this PR, all live connectors with a _distill_profile helper now have test coverage.

Test classes

Class Count What it covers
TestDistillProfile 11 Pure-function logic: minutes→hours conversion, recent titles capped at 10, fallback name, top-games sorting (desc by playtime), top-10 cap, heavy_session_hours sum-of-top-5 only, game_count passthrough
TestSteamConnectEndpoint 2 503 when steam_api_key not set; auth_url contains steamcommunity.com/openid when configured
TestSteamAnalyzeEndpoint 3 404 when no row; 404 when steam_data null; 200 with mocked chat_completion narrative

Coverage not included

  • /steam/callback — requires OpenID 2.0 assertion verification against live Steam endpoint + DB nonce table; not practical to unit-test without a heavier integration harness.

Test suite total (estimated)

~210 tests across 19 files after this PR.


Generated by Claude Code

@vercel

vercel Bot commented Aug 23, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
channelzero Ready Ready Preview Aug 23, 2026 4:05pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant