You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Feature has been introduced to support "title" as model name: #2868
However it has not been applied to some type of inline models (inline models defined within MapProperty and ArrayProperty. I see it as a bug in the feature introduced with Issue-2868.
Swagger-codegen version
2.2.1-SNAPSHOT
Swagger declaration file content or url
```java
@Test
public void resolveInlineArrayModelWithTitle() throws Exception {
Swagger swagger = new Swagger();
swagger.addDefinition("User", new ArrayModel()
.items(new ObjectProperty()
.title("InnerUserTitle")
._default("default")
.access("access")
.readOnly(false)
.required(true)
.description("description")
.name("name")
.property("street", new StringProperty())
.property("city", new StringProperty())));
new InlineModelResolver().flatten(swagger);
Model model = swagger.getDefinitions().get("User");
assertTrue(model instanceof ArrayModel);
Model user = swagger.getDefinitions().get("InnerUserTitle");
assertNotNull(user);
assertEquals("description", user.getDescription());
}
Description
Feature has been introduced to support "title" as model name:
#2868
However it has not been applied to some type of inline models (inline models defined within MapProperty and ArrayProperty. I see it as a bug in the feature introduced with Issue-2868.
Swagger-codegen version
2.2.1-SNAPSHOT
Swagger declaration file content or url
'''
Command line used for generation
Used Maven plugin to generate Java client
Steps to reproduce
See Unit Test above
Related issues
Issue-2868.
Suggest a Fix
I'm submitting pull request to fix this
The text was updated successfully, but these errors were encountered: