Skip to content

test: add session memory summary replay consistency harness#176

Open
LiMelson wants to merge 2 commits into
trpc-group:mainfrom
LiMelson:codex/replay-consistency-harness
Open

test: add session memory summary replay consistency harness#176
LiMelson wants to merge 2 commits into
trpc-group:mainfrom
LiMelson:codex/replay-consistency-harness

Conversation

@LiMelson

Copy link
Copy Markdown

Fixes #89

What

  • Add a reusable Session / Memory / Summary replay consistency harness.
  • Compare InMemory and SQLite replay snapshots.
  • Generate normalized diff reports with backend, case, field path, event index, and values.
  • Cover injected inconsistency detection for replay cases and summary loss, overwrite, and wrong session ownership.

Test

  • pytest tests/sessions/test_replay_consistency.py

@github-actions

github-actions Bot commented Jul 13, 2026

Copy link
Copy Markdown

CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅

@codecov

codecov Bot commented Jul 13, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (main@e113610). Learn more about missing BASE report.

Additional details and impacted files
@@            Coverage Diff             @@
##             main        #176   +/-   ##
==========================================
  Coverage        ?   87.55698%           
==========================================
  Files           ?         467           
  Lines           ?       44097           
  Branches        ?           0           
==========================================
  Hits            ?       38610           
  Misses          ?        5487           
  Partials        ?           0           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@LiMelson

Copy link
Copy Markdown
Author

I have read the CLA Document and I hereby sign the CLA

Rook1ex added a commit to trpc-group/cla-database that referenced this pull request Jul 13, 2026
@LiMelson

Copy link
Copy Markdown
Author

Updated the PR to include Redis replay integration coverage.

Additional verification:

  • pytest tests/sessions/test_redis_session_service.py -q
  • TRPC_REPLAY_REDIS_URL=redis://localhost:6379/0 pytest tests/sessions/test_replay_consistency.py -q

The generated diff report now includes in_memory, sqlite, and redis backends.

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.

构建 Session / Memory 多后端回放一致性测试框架

1 participant