Skip to content

Commit

Permalink
Fix review suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
lnash94 committed Feb 28, 2024
1 parent 9f0bf32 commit b42865e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,9 @@ public void generateClientAndService(String definitionPath, String serviceName,
List<String> complexPaths = GeneratorUtils.getComplexPaths(openAPIDef);
if (!complexPaths.isEmpty()) {
isResource = false;
outStream.println("remote function(s) will be generated for client and the service generation can not be " +
"proceed due to the given openapi definition contains following complex path(s):");
outStream.println("WARNING: remote function(s) will be generated for client and the service" +
" generation can not be proceed due to the given openapi definition contains following" +
" complex path(s):");
for (String path: complexPaths) {
outStream.println(path);
}
Expand Down Expand Up @@ -360,8 +361,8 @@ private List<GenSrcFile> generateClientFiles(Path openAPI, Filter filter, boolea
// Validate the service generation
List<String> complexPaths = GeneratorUtils.getComplexPaths(openAPIDef);
if (!complexPaths.isEmpty()) {
outStream.println("remote function(s) will be generated for client due to the given openapi definition" +
" contains following complex path(s):");
outStream.println("WARNING: remote function(s) will be generated for client due to the given openapi " +
"definition contains following complex path(s):");
for (String path: complexPaths) {
outStream.println(path);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -704,7 +704,7 @@ public void testForComplexPathInClient() {
OpenApiCmd cmd = new OpenApiCmd(standardOut, tmpDir, false);
new CommandLine(cmd).parseArgs(args);
cmd.execute();
Assert.assertTrue(outputStream.toString().contains("remote function(s) will be generated for client " +
Assert.assertTrue(outputStream.toString().contains("WARNING: remote function(s) will be generated for client " +
"due to the given openapi definition contains following complex path(s):" + System.lineSeparator() +
"/v4/spreadsheets/{spreadsheetId}/sheets/{sheetId}:copyTo" + System.lineSeparator() +
"/v4/spreadsheets/{spreadsheetId}/sheets/{sheetId}:copyFrom" + System.lineSeparator() +
Expand All @@ -724,7 +724,7 @@ public void testForComplexPathInBothClientAndService() {
OpenApiCmd cmd = new OpenApiCmd(standardOut, tmpDir, false);
new CommandLine(cmd).parseArgs(args);
cmd.execute();
Assert.assertTrue(outputStream.toString().contains("remote function(s) will be generated for client" +
Assert.assertTrue(outputStream.toString().contains("WARNING: remote function(s) will be generated for client" +
" and the service generation can not be proceed due to the given openapi definition contains" +
" following complex path(s):" + System.lineSeparator() +
"/v4/spreadsheets/{spreadsheetId}/sheets/{sheetId}:copyTo" + System.lineSeparator() +
Expand Down

0 comments on commit b42865e

Please sign in to comment.