feat: add InvalidPeriodException for NameCom adapter#62
Conversation
Throw InvalidPeriodException when the API returns an invalid years error (HTTP 400). Ordered ERROR_INVALID_YEARS before ERROR_INVALID_CONTACT in ERROR_MAP so the more specific pattern matches first.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review infoConfiguration used: Organization UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (3)
WalkthroughThe changes add support for handling invalid domain registration periods in the NameCom registrar adapter. A new exception class Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ 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
InvalidPeriodExceptionthrown when NameCom API returns "Invalid value for years" (HTTP 400)ERROR_INVALID_YEARSbeforeERROR_INVALID_CONTACTinERROR_MAPso the more specific pattern matches first (both share the'invalid value for'substring)400to the map entry for precise matchingTest plan
testGetPriceWithInvalidPeriodpasses — confirmsInvalidPeriodExceptionis thrown for invalid year valuesSummary by CodeRabbit
Bug Fixes
Tests