GeezerVison is showing github.com — Support programmatic registration of resource locks by vdmitrienko · Pull Request #3889 · junit-team/junit-framework
Conversation
vdmitrienko
commented
Jul 16, 2024
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Solves: #2677
Overview
Introduce adding shared resources programmatically via @ResourceLock(providers = ...) attribute
which accepts an array of one or more classes implementing ResourceLocksProvider interface.
It allows to add resources in runtime (immediately before starting execution on the engine level).
Resources can be distributed based on any test class / nested test class / test method attributes (e.g. package name, class / method name etc.) or any other user logic.
This approach serves as a more flexible and less verbose alternative for cases in which:
- adding lots of
@ResourceLock(value, mode) annotations manually may be inconvenient;
- shared resources are not known until runtime.
I hereby agree to the terms of the JUnit Contributor License Agreement.
Definition of Done
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
vdmitrienko
changed the title
Draft: Implement adding ExclusiveResource programmatically.
Implement adding ExclusiveResource programmatically.
Jul 17, 2024
vdmitrienko
changed the title
Implement adding ExclusiveResource programmatically.
Introduce adding 'shared resources' programmatically
Aug 6, 2024
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.
Looks very promising! Sorry for the late request to change the API.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
vdmitrienko reacted with thumbs up emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
…nto #2677_add_exclusive_resource_programmatically
|
Hi @marcphilipp
Maybe you have any updates regarding this PR?
|
marcphilipp reacted with eyes emoji
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Thanks! I'll take it from here.
Thank you!
This was my first contribution, and it was very interesting and valuable experience.
|
marcphilipp reacted with heart emoji
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
marcphilipp
changed the title
Introduce adding 'shared resources' programmatically
Allow determining exclusive resources programmatically
Oct 7, 2024
sbrannen
changed the title
Allow determining exclusive resources programmatically
Support programmatic registration of resource locks
Jan 26, 2025
This was referenced Feb 24, 2025
This was referenced Mar 17, 2025
This was referenced Apr 14, 2025
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
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.
|