Add list restart test for formatted paragraphs#92
Conversation
Reviewer's GuideUpdate paragraph detection to treat formatted paragraphs as plain paragraphs, and add integration and unit tests to verify list numbering restarts after formatted paragraphs. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Summary by CodeRabbit
WalkthroughExpand the logic in Changes
Sequence Diagram(s)sequenceDiagram
participant Test as Test Function
participant File as Input File
participant Lists as renumber_lists
participant Output as Output File
Test->>File: Read input lines
Test->>Lists: Call renumber_lists(input)
Lists->>Lists: Process lines, trim *, _, ` in paragraphs
Lists-->>Test: Return renumbered output
Test->>Output: Compare with expected output
Possibly related PRs
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🧰 Additional context used📓 Path-based instructions (1)**/*.rsInstructions used from: Sources:
⚙️ CodeRabbit Configuration File 🔇 Additional comments (2)
✨ Finishing Touches
🧪 Generate unit tests
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Hey @leynos - I've reviewed your changes and found some issues that need to be addressed.
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Actionable comments posted: 5
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (5)
src/lists.rs(1 hunks)tests/data/renumber_formatting_paragraph_expected.txt(1 hunks)tests/data/renumber_formatting_paragraph_input.txt(1 hunks)tests/integration.rs(1 hunks)tests/lists.rs(1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.rs
Instructions used from:
Sources:
⚙️ CodeRabbit Configuration File
🧬 Code Graph Analysis (1)
tests/lists.rs (1)
src/lists.rs (1)
renumber_lists(68-119)
🔇 Additional comments (2)
tests/lists.rs (1)
58-63: Solid regression coverageThe test accurately captures the new behaviour and keeps the suite readable.
tests/integration.rs (1)
1068-1079: Integration test fills the realism gapThe end-to-end check with external data files ensures real-world scenarios stay green.
Summary
Testing
make lintmake testhttps://chatgpt.com/codex/tasks/task_e_6878db4e32f88322a1a466414b729b37
Summary by Sourcery
Allow list numbering to restart after formatted paragraphs and add corresponding tests
New Features:
Tests: