### Question:
ProcessManagerStatus { public String getJsonMicroservicesStatus() { JsonArrayBuilder arrayBuilder = Json.createArrayBuilder(); NumberFormat nf = NumberFormat.getInstance(Locale.US); nf.setMaximumFractionDigits(2); microservicesStatus.forEach((key, status) -> { JsonObjectBuilder objectBuilder = Json.createObjectBuilder() .add("id", key != null ? key : "UNKNOWN") .add("status", status != null ? (status.getStatus() != null ? status.getStatus().toString() : "UNKNOWN") : "UNKNOWN") .add("percentage", status != null ? status.getPercentage() : 0); if (status != null && status.getContainerId() != null) { objectBuilder .add("containerId", status.getContainerId() != null ? status.getContainerId() : "UNKNOWN") .add("startTime", status.getStartTime()) .add("operatingDuration", status.getOperatingDuration()) .add("cpuUsage", nf.format(status.getCpuUsage())) .add("memoryUsage", String.format("%d", status.getMemoryUsage())); } arrayBuilder.add(objectBuilder); }); return arrayBuilder.build().toString(); } ProcessManagerStatus(); String getJsonMicroservicesStatus(); String getJsonRegistriesStatus(); int getRunningMicroservicesCount(); ProcessManagerStatus setRunningMicroservicesCount(int count); ProcessManagerStatus setMicroservicesStatus(String microserviceUuid, MicroserviceStatus status); ProcessManagerStatus setMicroservicesState(String microserviceUuid, MicroserviceState state); MicroserviceStatus getMicroserviceStatus(String microserviceUuid); void removeNotRunningMicroserviceStatus(); int getRegistriesCount(); Map<Integer, LinkStatus> getRegistriesStatus(); ProcessManagerStatus setMicroservicesStatePercentage(String microserviceUuid, float percentage);  }### Answer:
@Test public void testGetJsonMicroservicesStatus() { assertEquals(arrayBuilder.build().toString(), processManagerStatus.getJsonMicroservicesStatus()); }