OpenAPITools / openapi-generator

OpenAPI Generator allows generation of API client libraries (SDK generation), server stubs, documentation and configuration automatically given an OpenAPI Spec (v2, v3)
https://openapi-generator.tech
Apache License 2.0
20.62k stars 6.29k forks source link

[BUG] [JAVA] Wrong Enum name generated #19081

Open rogeriobautz opened 4 days ago

rogeriobautz commented 4 days ago
Description

The enum constants names are being cut off when they have the equals first parts before an underline.

public enum EnumCalculation {

  UTEIS("DIAS_UTEIS"),

  CORRIDOS("DIAS_CORRIDOS");

  private String value;

//...
}
openapi-generator version

7.7.0

OpenAPI declaration file content or url

Complete file issues.zip

Generation Details

npx @openapitools/openapi-generator-cli generate -i issues.yml -g java -o ./tmp/test/ --additional-properties=useJakartaEe=true,serializationLibrary=jackson,library=microprofile,useBeanValidation=true

Steps to reproduce

Install operaapi-generator-cli and run the command above

jpfinne commented 3 days ago

same as #18889