EhrNumOneController { @RequestMapping(value = "/parseC32", method = RequestMethod.POST) public @ResponseBody GreenCCD parseC32(@RequestParam("c32Xml") String c32xml) throws C32ParserException { GreenCCD greenCcd = c32Parser.ParseC32(c32xml); return greenCcd; }  @RequestMapping(method = RequestMethod.GET) @ResponseBody EhrNumOneDto get(); @RequestMapping(value = "/c32/{patientId}", method = RequestMethod.GET) @ResponseBody String getC32(@PathVariable("patientId") String patientId); @RequestMapping(value = "/parseC32", method = RequestMethod.POST) @ResponseBody GreenCCD parseC32(@RequestParam("c32Xml") String c32xml); void setC32Getter(C32Getter c32Getter); void setC32Parser(C32Parser c32Parser);  }
@Test public void testParseC32() throws C32ParserException { String c32XmlMock = "c32XmlMock"; GreenCCD greenCCDMock = mock(GreenCCD.class); when(c32ParserMock.ParseC32(c32XmlMock)).thenReturn(greenCCDMock); GreenCCD actualObj = sut.parseC32(c32XmlMock); assertEquals(greenCCDMock, actualObj); }