@GET
  @Path("enabledPackage")
  public Response getAllEnabledPackageInfo() {
    try {
      return new JsonResponse<>(Response.Status.OK, "", helium.getAllEnabledPackages()).build();
    } catch (RuntimeException e) {
      logger.error(e.getMessage(), e);
      return new JsonResponse<>(Response.Status.INTERNAL_SERVER_ERROR, e.getMessage()).build();
    }
  }
@Test
  void testGetAllEnabledPackageInfo() throws IOException {
    // No enabled packages initially
    CloseableHttpResponse get1 = httpGet("/helium/enabledPackage");
    assertThat(get1, isAllowed());
    Map<String, Object> resp1 = gson.fromJson(EntityUtils.toString(get1.getEntity(), StandardCharsets.UTF_8),
                new TypeToken<Map<String, Object>>() { }.getType());
    List<Map> body1 = (List<Map>) resp1.get("body");
    assertEquals(0, body1.size());

    // Enable "name1" package
    helium.enable("name1", "artifact1");

    CloseableHttpResponse get2 = httpGet("/helium/enabledPackage");
    assertThat(get2, isAllowed());
    Map<String, Object> resp2 = gson.fromJson(EntityUtils.toString(get2.getEntity(), StandardCharsets.UTF_8),
            new TypeToken<Map<String, Object>>() { }.getType());
    List<Map> body2 = (List<Map>) resp2.get("body");

    assertEquals(1, body2.size());
    Map pkg = (Map) body2.get(0).get("pkg");
    assertEquals("name1", pkg.get("name"));
    get1.close();
    get2.close();
  }