Skip to content
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

fix: simplify reset database extension #779

Merged
merged 1 commit into from
Jan 23, 2025

Conversation

nikophil
Copy link
Member

@nikophil nikophil commented Jan 5, 2025

⚠️ this PR is build on top of #763 which needs to be reviewed/merged before this one

fixes #770
fixes #771 (I guess 😅)

At first, I used private services names for the resetters, and added a public alias (OrmResetter) which purpose was to be used to decorate the resetters (see docs). But this was clumsy, because when an alias is decorated, the decorator does not inherit the tags from the decorated. Which made the whole extension system complex.

Now, the resetter service name is directly the name of the service which needs to be decorated, as stated in the docs. No more alias.
I've also added some tests so we know it just work

ping @Nyholm @javiereguiluz this is going to land in the next release :)

@nikophil nikophil changed the title fix/database reset extension fix: simplify reset database extension Jan 5, 2025
@nikophil nikophil requested a review from kbond January 5, 2025 18:44
@nikophil nikophil force-pushed the fix/database-reset-extension branch 2 times, most recently from 82d1f29 to a95929c Compare January 5, 2025 20:22
Copy link
Member

@kbond kbond left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻

@nikophil nikophil force-pushed the fix/database-reset-extension branch from a95929c to 2677eed Compare January 23, 2025 17:20
@nikophil nikophil force-pushed the fix/database-reset-extension branch from 2677eed to 0562be0 Compare January 23, 2025 17:31
@nikophil nikophil merged commit 884113f into zenstruck:2.x Jan 23, 2025
86 checks passed
@nikophil nikophil deleted the fix/database-reset-extension branch January 23, 2025 17:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants