Closed abelsromero closed 1 year ago
I just realized we publish the asciidoctorj-test-support
artifact.
Right now I have a JUnit5 extension that offers:
@ClassResource
will inject a shared Asciidoctor instance into a test field.@TestMethodResource
will inject an new Asciidoctor for each test method.@ClasspathResource("test.txt")
will inject a file from classpath. Can be used as filed or test parameters.With that, we cover our needs, but maybe the ClassResource
and TestMethodResource
nomenclature is not very clear for users. Any suggestion, I was thinking calling it @AsciidoctorInstance
with a property that accepts an enum to be shared or not :thinking:
Made some more progress :tada: the arquillian extension is not used but we can keep it, and only the wildfly-integration-test module uses junit 4 now.
I am also thinking renaming asciidoctorj-test-support
to asciidoctorj-junit-extenasion
, that would make it's intent clear, and that way it can awaken interest from users.
Ready :tada:
Thank you for this! This is awesome! 🙌
Kind of change
Description
What is the goal of this pull request?
Complete #1186. JUnit5 is the default now (only used in 'asciidoctorj-wildfly-integration-test' because of Arquillian). And we have a new JUnit5 tools. The Arquillian extension is left untouched.
How does it achieve that?
Replace Junit4 by Junit5
Are there any alternative ways to implement this?
Not on the base implementation, but the naming of the JUnit5 extensions annotations is open for debate :sweat_smile: (naming is hard).
Are there any implications of this pull request? Anything a user must know?
No.
Issue
This completely closes the issue :tada:
Fixes #1186
Release notes
Please add a corresponding entry to the file CHANGELOG.adoc
Already added.