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

Add @Inherited to annotations targeting ElementType.TYPE #456

Closed
beatngu13 opened this issue Apr 7, 2021 · 2 comments · Fixed by #634
Closed

Add @Inherited to annotations targeting ElementType.TYPE #456

beatngu13 opened this issue Apr 7, 2021 · 2 comments · Fixed by #634

Comments

@beatngu13
Copy link
Member

See this comment:

As pointed out by @Michael1993 in #449, there are more annotations – besides the environment variable and system property extensions – we should consider making @Inherited.

I believe this only makes sense for annotations targeting ElementType.TYPE, since we are dealing with test base classes. Searching for ElementType.TYPE yields:

* `@DefaultLocale`

* `@DefaultTimeZone`

* `@Issue`

* `@Stopwatch`

Plus all the @Reads*/@Writes* annotations.

So, I tend to reopen this issue until we make the above @Inherited, too. What do you guys think?

As suggested by @nipafx, "one PR per extension" is preferred.

Example PR/changes for entry-based annotations (i.e. environment variable and system property extensions): #449

@beatngu13
Copy link
Member Author

Side note: In contrast to #448, I labeled this issue as "enhancement" rather than "bug". IMHO the annotations/extensions basically work as expected, adding @Inherited is new functionality. However, in case somebody disagrees, feel free to adjust the corresponding label.

@Bukama
Copy link
Member

Bukama commented Apr 8, 2021

I also see this as new functionality. We need to keep in mind that nothing gets broken, esp. @Issue should be carefully watched as the search for the annotation not only happens in one place.

@Michael1993 Michael1993 added this to Ready to get started in Up for grabs... Apr 13, 2021
@beatngu13 beatngu13 added this to To do in Pioneer 2.0 via automation Mar 24, 2022
beatngu13 added a commit that referenced this issue Apr 7, 2022
`@DefaultLocale` and `@DefaultTimeZone` are now `@Inherited`.

Relates to: #456
PR: #615
@beatngu13 beatngu13 added this to the Busy Pioneers - V2.0 milestone Apr 28, 2022
@nipafx nipafx removed this from To do in Pioneer 2.0 Apr 28, 2022
@nipafx nipafx linked a pull request May 14, 2022 that will close this issue
14 tasks
nipafx pushed a commit that referenced this issue May 17, 2022
Expand contribution guide with explanation how to make extensions
reusable, namely:

* allow as meta-annotation and use our and Jupiter's tools to find
  annotations
* allow inheritance by applying `@Inherited`

This change also applies `@Inherited` where it wasn't already.

Closes: #456
PR: #634
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Up for grabs...
Ready to get started
Development

Successfully merging a pull request may close this issue.

3 participants