mojohaus / jaxb2-maven-plugin

JAXB2 Maven Plugin
https://www.mojohaus.org/jaxb2-maven-plugin/
Apache License 2.0
106 stars 77 forks source link

schemagen won't add JavaDoc annotations when class name contains underscore #93

Open libertysoftware opened 7 years ago

libertysoftware commented 7 years ago

Plugin: jaxb2-maven-plugin Version: 2.3.1

Scenario: I have a Java class with JAXB annotations and JavaDocs on fields. JAXB is configured to generate schema based on FIELDS.

Expected result: XSD schema is generated and contains documentation annotations picked from JavaDoc comments in source java class.

Actual result: XSD schema doesn't contain documentation annotations.

Observation: Actual result only happens if java class contains underscore in it's name (e.g. DummyRequest_v1.java)

lennartj commented 6 years ago

I presume that you mean in your observation that XSD documentation annotations are only added when the class name does not contain underscores, right?

This seems like a bug in the pattern matching within the JavaDoc processor. Could you create an IT with this situation?

libertysoftware commented 6 years ago

The bug(comments from Javadoc not copied into XSD) manifests itself only when the class name contains an underscore. What is an IT?

lennartj commented 6 years ago

Ah. "IT" == "Integration Test".

You can find all the integration tests under src/it within the codebase.