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

Improve handling of @Parameter's defaultValue #609

Closed
1 of 3 tasks
abelsromero opened this issue Jan 22, 2023 · 0 comments
Closed
1 of 3 tasks

Improve handling of @Parameter's defaultValue #609

abelsromero opened this issue Jan 22, 2023 · 0 comments

Comments

@abelsromero
Copy link
Member

abelsromero commented Jan 22, 2023

What is this issue about?

  • Bug report
  • Feature request
  • Question

Description

The Maven mojos can use defaultValue to set the default value of a configuration property. However, that is not respected in unit tests where we create a mojo with mockAsciidoctorMojo method.
Test work thanks to a combination of manually set defaults and code validations that should not be necessary.

Basic thing to do is parse annotations to set values in unit tests to get a 100% consistent testing experience. We can experiment with doing it in current mockAsciidoctorMojo or do some junit extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant