Skip to content

test: optimize test suite — parametrize duplicates, delete redundant files - #60

Closed
Cipher208 wants to merge 8 commits into
masterfrom
test-optimization-pr
Closed

test: optimize test suite — parametrize duplicates, delete redundant files#60
Cipher208 wants to merge 8 commits into
masterfrom
test-optimization-pr

Conversation

@Cipher208

Copy link
Copy Markdown
Owner

Summary

  • Delete 7 duplicate test files (-38 tests)
  • Reduce test_core, test_features, test_auth_backup, test_integration to unique tests only
  • Parametrize 6 test files: importance_v2, rag_scoring, rag_search_facade, memory_types, mib_quantize

Results

Metric Before After
Test functions ~195 ~140
Test cases (with parametrize) 270 346
Coverage 77% 80%
Test files 65 58

Changes

  • Deleted: test_all.py, test_mcp/test_mcp.py, test_lifecycle/test_lifecycle.py, test_hooks/test_hooks.py, test_graph/test_graph.py, test_rag/test_rag.py, test_rag/test_rag_edge_cases.py
  • Reduced: test_core (6→1), test_features (6→1), test_auth_backup (23→14), test_integration (42→15)
  • Parametrized: test_importance_v2, test_rag_scoring, test_rag_search_facade, test_memory_types, test_mib_quantize, test_conflict_bm25

Verification

  • All tests pass (346/346)
  • ruff: 0 errors
  • mypy: 0 errors
  • Coverage: 80%

Ariel Memory added 8 commits July 6, 2026 11:07
Deleted exact copies of test_integration.py and test_auth_backup.py:
- test_all.py: duplicates test_core + test_features + test_mcp
- test_mcp/test_mcp.py: exact copy of test_auth_backup.py
- test_lifecycle/test_lifecycle.py: copies test_integration.py
- test_hooks/test_hooks.py: copies test_integration.py
- test_graph/test_graph.py: copies test_integration.py
- test_rag/test_rag.py: copies test_integration.py
- test_rag/test_rag_edge_cases.py: overlap with test_integration + search_facade
Kept: test_reflex_buffer (unique L1 buffer test), test_compression (unique feature)
Removed: 5 core tests + 5 feature tests that duplicated test_integration.py
…0 tests)

Removed: backup(4), audit(3), rate_limiter(2), import_export(1)
All duplicated by test_integration.py
Kept: remember/recall/forget (parametrized user/agent), rag (4), saga, middleware,
embeddings, migrations, connection_manager, dashboard, metrics.
Removed: duplicate tests covered by test_tools_e2e.py and unit tests.
Consolidated: noise detection (2→1 parametrized), technical keywords (2→1 parametrized),
question bonus (1→1 parametrized), total_in_unit_interval (1→1 parametrized).
All invariants preserved, 15→22 test cases (more coverage, fewer test functions).
Consolidated: ScoringWeights (2→1 parametrized), CorpusStats (3→1 parametrized),
relevance_score (2→1 parametrized), type_boost (3→1 parametrized with 8 cases).
Kept unique: novelty edge cases, rank_sync ordering/novelty/boost, rank_async.
Consolidated: auto_strategy (4→1 parametrized), mib/hybrid (2→1 parametrized),
format_result (2→1 parametrized). Kept unique: strategy init, materialize, user filtering.
…ons)

memory_types: validate_kind (2→1 parametrized), can_archive (5→2 parametrized),
kind_for_text (4→1 parametrized). mib_quantize: embed_to_binary (2→1 parametrized),
hamming_distance (2→1 parametrized), edge_cases (3→1 parametrized).
@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@coderabbitai

coderabbitai Bot commented Jul 6, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: c70e9f18-d48b-479e-bd54-ebc5e8493474

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@Cipher208 Cipher208 closed this Jul 6, 2026
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.

2 participants