-
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add spec coverage for models/form/custom_emoji_batch
class
#28388
Add spec coverage for models/form/custom_emoji_batch
class
#28388
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #28388 +/- ##
==========================================
+ Coverage 83.49% 83.67% +0.18%
==========================================
Files 1038 1038
Lines 28245 28245
Branches 4558 4558
==========================================
+ Hits 23584 23635 +51
+ Misses 3534 3482 -52
- Partials 1127 1128 +1 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we do without the refactor? I'm afraid this could lead to different object shapes because the i-var would not be defined for every instance.
766842c
to
62b89a7
Compare
Removed the memoization method, just the specs now. I believe in ruby 3.3 there's some improved performance/warning mode that you can run with to help identify |
Yeah, that sounds like a good idea! |
Required adding another fabricator. Gets close to full coverage on the class, including the main
action
option paths through the save method. Pulled out a private method for the two ways of finding categories in the update action.If we wanted more refactor - there is probably a way here to better aggragate the permissions checks up front, and/or group together the "pairsed" options (list/unlist, enable/disble) ... but I wanted to keep this coverage focused on this pass.