Skip to content

test(storage): cover migration source collection grants - #158

Merged
M3gA-Mind merged 1 commit into
release/v0.1.42from
fix/legacy-migration-grants
Oct 26, 2026
Merged

M3gA-Mind merged 1 commit into
release/v0.1.42from
fix/legacy-migration-grants

Conversation

@senamakel

Copy link
Copy Markdown
Member

Add a regression test that requires every legacy collection read by TinyChannels migrations to remain in the storage collection declaration.

The release branch already includes the collection grant fix; this test pins the contract so the module can keep migrating v0.1.42 data under host-scoped storage.

Validation: cargo test --manifest-path crates/tinychannels-bus/Cargo.toml --features storage storage::schema::tests:: (2 passed).

Co-authored-by: Medulla <medulla@tinyhumans.ai>
@tinysweeper

tinysweeper Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Tiny Sweeper review

Reviewed head: fcb0497276b5f2eed4cf4a09ad9189f749b40841

Findings

No active actionable findings.

Advisory notes

  • medium: Pin legacy migration sources against the defined constants ((pull request description))
    Problem: The description promises this test "requires every legacy collection read by TinyChannels migrations to remain in the storage collection declaration," but the loop only iterates `M
    Suggested fix:
    No concrete fix was supplied.

Verdict: Ready for maintainer review · Priority: none
Coverage: Reviewed 1 of 1 files.

Diagnostics and supporting details

Full summary

Pull request purpose (title): test(storage): cover migration source collection grants. Tiny Sweeper completed its review; deterministic results follow.

Review snapshot

Change surface Files Review signal Count
Production 0 Active findings 0
Tests 1 Noted findings 1
Documentation 0 Resolved findings 0
Configuration 0 Pending checks/questions 0

Completeness: Complete
Test assessment: No supported feature-to-test mapping was available; this does not mean tests are absent or passed.

What changed

A single test file gained one test (`collections_include_every_legacy_migration_source`) that reads `collections()` and `MIGRATION_SOURCE_COLLECTIONS` and asserts each migration source name appears in the declared collection names. There is no behavior change to storage or migrations; the change only pins a contract in test code.

Features

None identified with supported citations.

Tests

No supported feature-to-test mapping was produced. Test execution is not inferred.

Before merge

None.

Agent review details

critique

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: Answered with no findings: the read-only assertion holds against the current `COLLECTIONS` array and introduces no defect.
  • Lane summary: The added test only asserts that every legacy migration source constant is present in `collections()`, which holds for the current `COLLECTIONS` array (all 14 legacy names are declared). It is a read-only check that cannot fail on current code and introduces no defect. _The code index is behind this pull request (indexed at `ec6bdf9de885`), so retrieved context may be out of date._

security

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: Answered with no findings: the test-only change introduces no untrusted input, sink, or rule violation.
  • Lane summary: The new test only compares the declared collection names against MIGRATION_SOURCE_COLLECTIONS, both already present in schema.rs; LEGACY_WHATSAPP_* and legacy delivery/remote names are all in COLLECTIONS, so the assertion passes. No untrusted input, sink, or rule violation is introduced by this test-only change. _The code index is behind this pull request (indexed at `ec6bdf9de885`), so retrieved context may be out of date._

tests

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: Answered that the new test pins the invariant and fails if a constant is dropped from `COLLECTIONS`; described as deterministic rather than vacuous.
  • Lane summary: This diff adds one test that pins an invariant: every legacy migration source collection appears in `collections()`. The commit's own claim ("every legacy source collection read or created by a storage migration") is now backed by a test that fails if a constant is dropped from `COLLECTIONS`, which is exactly the evidence the invariant needed. The test is deterministic and cannot pass vacuously while a source is missing, and no production code changed, so no other test is warranted. Nothing to report. _The code index is behind this pull request (indexed at `ec6bdf9de885`), so retrieved context may be out of date._

commits

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: Answered with no findings: no sensitive content in committed files.
  • Lane summary: No sensitive content in committed files. _The code index is behind this pull request (indexed at `ec6bdf9de885`), so retrieved context may be out of date._

description

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Lane summary: The PR adds a single test in `crates/tinychannels-bus/src/storage/schema_tests.rs` that asserts every entry of `MIGRATION_SOURCE_COLLECTIONS` is present in the collection declarations, matching the description; the test lives in the sibling `_tests.rs` file as the repo rules require and calls only symbols already visible in the diff. One gap: the description claims the test covers "every legacy collection read by TinyChannels migrations," but `MIGRATION_SOURCE_COLLECTIONS` is a list written alongside `COLLECTIONS` in the same file — adding a new legacy constant without listing it there would silently keep the test green, which is a coverage claim stronger than what the change enforces. _The code index is behind this pull request (indexed at `ec6bdf9de885`), so retrieved context may be out of date._
Evidence and run details
  • Models: ladder/vectors-oai3, deepseek-v4.1-flash
  • Spend: $0.000121
  • Tokens: 101477 input · 2805 output · 44032 cached · 63 embedding
  • Updated: 2026-10-25T10:30:11Z
Head State Pass summary
fcb0497276b5 ready for maintainer review 0 active finding(s), 0 resolved finding(s) (at 2026-10-25T10:30:11Z)

tinysweeper 0.1.2

@coderabbitai

coderabbitai Bot commented Oct 25, 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
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 458326f7-83cf-4e4d-bdbd-b6da2a295d21

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
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-25T10:30:33.604473Z fcb0497 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@tinysweeper tinysweeper Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tinysweeper found nothing blocking. Approving.

Diagnostics

Total spend: $0.0001

@tinysweeper tinysweeper Bot added the priority: p3 Whenever. Cosmetic, a nicety, or a cleanup with no user visible effect. label Oct 25, 2026
@M3gA-Mind
M3gA-Mind merged commit 2646d0d into release/v0.1.42 Oct 26, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

priority: p3 Whenever. Cosmetic, a nicety, or a cleanup with no user visible effect.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants