Light, fluffy, and always free - The AWS Local Emulator alternative
fix(apigateway): report RestApi as available (#2816)
BingEdward62dbd9ddf953
diff --git a/src/main/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayController.java b/src/main/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayController.javaindex 7b650546f1..1102562127 100644--- a/src/main/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayController.java+++ b/src/main/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayController.java@@ -1908,6 +1908,7 @@ public class ApiGatewayController {node.put("name", api.getName());if (api.getDescription() != null) node.put("description", api.getDescription());node.put("createdDate", api.getCreatedDate());+ node.put("apiStatus", "AVAILABLE");if (api.getTags() != null && !api.getTags().isEmpty()) {ObjectNode tagsNode = objectMapper.createObjectNode();api.getTags().forEach(tagsNode::put);diff --git a/src/test/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayIntegrationTest.java b/src/test/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayIntegrationTest.javaindex 979db070bf..d3aa5d3d85 100644--- a/src/test/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayIntegrationTest.java+++ b/src/test/java/io/github/hectorvent/floci/services/apigateway/ApiGatewayIntegrationTest.java@@ -35,6 +35,7 @@ class ApiGatewayIntegrationTest {.body("id", notNullValue()).body("name", equalTo("test-api")).body("description", equalTo("Integration test API"))+ .body("apiStatus", equalTo("AVAILABLE")).extract().path("id");}@@ -45,7 +46,8 @@ class ApiGatewayIntegrationTest {.then().statusCode(200).body("id", equalTo(apiId))- .body("name", equalTo("test-api"));+ .body("name", equalTo("test-api"))+ .body("apiStatus", equalTo("AVAILABLE"));}@Test @Order(3)