@Test public void listScChamberDivisions() throws Exception { ResultActions actions = mockMvc.perform(get("/sc/chambers/" + chamberId + "/chamberDivisions/list") .accept(MediaType.APPLICATION_JSON)); actions .andExpect(status().isOk()) .andExpect(jsonPath("$.[0].id").value(equalsLong(simpleEntities.get(0).getId()))) .andExpect(jsonPath("$.[0].name").value(simpleEntities.get(0).getName())) .andExpect(jsonPath("$.[1].id").value(equalsLong(simpleEntities.get(1).getId()))) .andExpect(jsonPath("$.[1].name").value(simpleEntities.get(1).getName())); verify(scListService, times(1)).findScChamberDivisions(chamberId); }
@RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody public List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId) { return scListService.findScChamberDivisions(supremeChamberId); }
ScListController { @RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody public List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId) { return scListService.findScChamberDivisions(supremeChamberId); } }
ScListController { @RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody public List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId) { return scListService.findScChamberDivisions(supremeChamberId); }  }
ScListController { @RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody public List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId) { return scListService.findScChamberDivisions(supremeChamberId); }  @RequestMapping("sc/chambers/list") @ResponseBody List<SimpleEntity> listScChambers(); @RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId); @RequestMapping("/sc/judgmentForms/list") @ResponseBody List<SimpleEntity> listScJudgmentForms(); }
ScListController { @RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody public List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId) { return scListService.findScChamberDivisions(supremeChamberId); }  @RequestMapping("sc/chambers/list") @ResponseBody List<SimpleEntity> listScChambers(); @RequestMapping("sc/chambers/{supremeChamberId}/chamberDivisions/list") @ResponseBody List<SimpleEntity> listScChamberDivisions(@PathVariable("supremeChamberId") long supremeChamberId); @RequestMapping("/sc/judgmentForms/list") @ResponseBody List<SimpleEntity> listScJudgmentForms();  }