Skip to content

@Tag name parameter not consistently performing lookup on properties file #1351

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

Closed
ianwallen opened this issue Nov 28, 2021 · 0 comments
Closed
Labels
bug Something isn't working

Comments

@ianwallen
Copy link
Contributor

Describe the bug
@tag name is being parsed differently depending on the parameters supplied to the annotation.

i.e.
In the unit test App14 (https://github.com/springdoc/springdoc-openapi/tree/master/springdoc-openapi-webmvc-core/src/test/java/test/org/springdoc/api/app14)

@Tag(name = "greeting")
Produces the following in the unit test.
"tags":["Change the language","Hello! Welcome to our website!"]

But changing the @tag to include a description causes the name parameter to no longer load from properties file.
@Tag(name = "greeting", description = "greeting")
Produces
"tags":[{"name":"greeting","description":"greeting"}]

To Reproduce
Modify the following line in the unit test.

@Tag(name = "greeting", description = "greeting")

Run the test and check the body that was returned in the error message.

Expected behavior
I would expect that both Name and Description would have converted from the properties file to product "Hello! Welcome to our website!"
I also expect that adding a new parameter should not change the results of how the name parameter is loaded from the properties file.

@bnasslahsen bnasslahsen added the bug Something isn't working label Jan 10, 2022
mpleine pushed a commit to mpleine/springdoc-openapi that referenced this issue May 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants