zhfeng commented on code in PR #12269:
URL: https://github.com/apache/camel/pull/12269#discussion_r1410355768
##########
components/camel-openapi-java/src/test/java/org/apache/camel/openapi/RestOpenApiReaderTest.java:
##########
@@ -170,6 +251,14 @@ public void testReaderRead() throws Exception {
assertTrue(json.contains("\"success\" : \"123\""));
assertTrue(json.contains("\"error\" : \"-1\""));
assertTrue(json.contains("\"type\" : \"array\""));
+ assertTrue(json.contains("\"enum\" : [ \"A\", \"B\", \"C\" ]"));
+ assertTrue(json.contains("\"enum\" : [ 1, 2, 3 ]"));
+ assertTrue(json.contains("\"enum\" : [ 1.0, 2.0, 3.0 ]"));
+ assertTrue(json.contains("\"enum\" : [ \"true\", \"false\" ]"));
Review Comment:
It looks like swagger v2 does not convert `Boolean` value. see
https://github.com/swagger-api/swagger-core/blob/v1.6.11/modules/swagger-models/src/main/java/io/swagger/models/parameters/AbstractSerializableParameter.java#L173-L192
So there is a String `true` and `false` . @jamesnetherton is this a problem?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]