Skip to content

Repeatable QuarkusTestResource do not work on kotlin #11856

@CVeniamin

Description

@CVeniamin

Describe the bug
Unable to use repeatable @QuarkusTestResource in kotlin.

Consider the following example:

@QuarkusTestResource(ResourceOne::class)
@QuarkusTestResource(ResourceTwo::class)
class Test {
...
}

does not work, giving the following error: Repeatable annotations with non-SOURCE retention are not yet supported.
This was already reported on #5252 and fixed as part of PR #5473

I think this is solvable by changing Retention to @Retention(AnnotationRetention.SOURCE) rather than @Retention(RetentionPolicy.RUNTIME).

Expected behavior
Should be allowed to use repeatable @QuarkusTestResource annotations and test should be compile.

Actual behavior
Fails to compile the tests.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions