test: fill coverage gaps (female encode, individual fields, round-trips, year/gender boundaries)#74
test: fill coverage gaps (female encode, individual fields, round-trips, year/gender boundaries)#74matteoredz wants to merge 2 commits into
Conversation
…ities or countries Previously the birthplace method returned nil implicitly when the stop: true recursive call found nothing, masking invalid tax codes silently. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…round-trips, year/gender boundaries Adds T1 (female +40 day offset encoding), T2 (individual nil-field MissingDataError tests), T3 (encode→decode round-trips for male, female, and foreign), T4 (in_dates? false-branch via Mocha stub), T5 (year century-rollback boundary with Timecop), and T6 (day 31 male / day 41 female gender boundary). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Warning Review limit reached
More reviews will be available in 59 minutes and 36 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (5)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
gender: "F"appliesday + 40offset.MissingDataErrortests per required field (surname, name, gender, birthdate, birthplace each set tonilindividually with all others valid).in_dates?false-path coverage: stubs cities via Mocha to expose an F205 entry whose validity window excludes the decoded birthdate →InvalidTaxCodeErrorraised (depends onfix/birthplace-nil-returnbeing merged first)."26"→ 2026 (≤ current year, else branch); year code"27"→ 1927 (> current year, subtract 100).Test plan
fix/birthplace-nil-return(fix(parser): raise InvalidTaxCodeError when birthplace not found #72) first (T4 depends on theInvalidTaxCodeErrorraise)mainafter fix(parser): raise InvalidTaxCodeError when birthplace not found #72 landsbundle exec rakegreen with 100% line + branch coveragebundle exec rubocopclean on changed files🤖 Generated with Claude Code