public void run() {
        populateTestData();
        final WS.Response response = WS.url(BASE_URL + REST_USER_RESOURCE_USAGE_PATH).
            setQueryParameter("startTime", TEST_START_TIME1).
            setQueryParameter("endTime", TEST_END_TIME1).
            get().get(RESPONSE_TIMEOUT, TimeUnit.MILLISECONDS);
        Iterator<JsonNode> userResources = response.asJson().elements();
        while (userResources.hasNext()) {
          JsonNode userResourceUsage = userResources.next();
          if (userResourceUsage.findValue("user").asText().equals("growth")) {
            assertTrue("Wrong resourceusage for user growth",
                userResourceUsage.findValue("resourceUsed").asDouble() == Utils.MBSecondsToGBHours(100));
            assertTrue("Wrong wastedResources for user growth",
                userResourceUsage.findValue("resourceWasted").asDouble() == Utils.MBSecondsToGBHours(30));
          } else if (userResourceUsage.findValue("user").asText().equals("metrics")) {
            assertTrue("Wrong resourceusage for user metrics",
                userResourceUsage.findValue("resourceUsed").asDouble() == Utils.MBSecondsToGBHours(200));
            assertTrue("Wrong wastedResources for user metrics",
                userResourceUsage.findValue("resourceWasted").asDouble() == Utils.MBSecondsToGBHours(40));
          } else {
            assertTrue("Unexpected user" + userResourceUsage.findValue("user").asText(), false);
          }
        }
      }
<p>
Rest API  - Provides data for plotting the flow history graph for time and resources
</p>
test/rest/RestAPITest.java