@Test public void testGetMeasureNamesGroupByOrg() throws Exception { List<String> measures = Arrays.asList("measureName"); Map<String, List<String>> map = new HashMap<>(); map.put("orgName", measures); when(measureOrgService.getMeasureNamesGroupByOrg()).thenReturn(map); mockMvc.perform(get(URLHelper.API_VERSION_PATH + "/org/measure/names")) .andExpect(status().isOk()) .andExpect(jsonPath("$.orgName", hasSize(1))); }
@RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) public Map<String, List<String>> getMeasureNamesGroupByOrg() { return measureOrgService.getMeasureNamesGroupByOrg(); }
MeasureOrgController { @RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) public Map<String, List<String>> getMeasureNamesGroupByOrg() { return measureOrgService.getMeasureNamesGroupByOrg(); } }
MeasureOrgController { @RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) public Map<String, List<String>> getMeasureNamesGroupByOrg() { return measureOrgService.getMeasureNamesGroupByOrg(); }  }
MeasureOrgController { @RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) public Map<String, List<String>> getMeasureNamesGroupByOrg() { return measureOrgService.getMeasureNamesGroupByOrg(); }  @RequestMapping(value = "/org", method = RequestMethod.GET) List<String> getOrgs(); @RequestMapping(value = "/org/{org}", method = RequestMethod.GET) List<String> getMetricNameListByOrg(@PathVariable("org") String org); @RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) Map<String, List<String>> getMeasureNamesGroupByOrg(); }
MeasureOrgController { @RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) public Map<String, List<String>> getMeasureNamesGroupByOrg() { return measureOrgService.getMeasureNamesGroupByOrg(); }  @RequestMapping(value = "/org", method = RequestMethod.GET) List<String> getOrgs(); @RequestMapping(value = "/org/{org}", method = RequestMethod.GET) List<String> getMetricNameListByOrg(@PathVariable("org") String org); @RequestMapping(value = "/org/measure/names", method = RequestMethod.GET) Map<String, List<String>> getMeasureNamesGroupByOrg();  }