[legacy_promotions]: Correct decorator naming#5946
Merged
tvdeyen merged 1 commit intosolidusio:mainfrom Dec 3, 2024
Merged
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5946 +/- ##
==========================================
+ Coverage 87.81% 89.45% +1.64%
==========================================
Files 476 782 +306
Lines 11656 17997 +6341
==========================================
+ Hits 10236 16100 +5864
- Misses 1420 1897 +477 ☔ View full report in Codecov by Sentry. |
c6f6c47 to
fe18ce3
Compare
adammathys
approved these changes
Nov 20, 2024
tvdeyen
reviewed
Nov 20, 2024
fe18ce3 to
e639857
Compare
If we want to use these decorators with Zeitwerk, their naming scheme has to exchange module name and type. For example, app/decorators/solidus_legacy_promotions/models/line_item_decorator.rb becomes app/decorators/models/solidus/legacy_promotions/line_item_decorator.rb This will eventually allow us to use Zeitwerk for loading decorators.
e639857 to
e306a14
Compare
jarednorman
approved these changes
Dec 2, 2024
Member
|
Backport after #6016 |
💔 All backports failed
Manual backportTo create the backport manually run: Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This changes the file names of decorators in the
solidus_legacy_promotionsgem to match Zeitwerk's expectations.solidus_promotionsis actually entirely fine.This has been tested with solidusio/solidus_support#87, but is fully compatible with the classic way of loading each and every decorator on every app reload.
Checklist
Check out our PR guidelines for more details.
The following are mandatory for all PRs: