### Question:
StationController { @DeleteMapping(value = "/stations") public ResponseEntity<Response> delete(@RequestBody Station station, @RequestHeader HttpHeaders headers) { return ok(stationService.delete(station, headers)); }  @GetMapping(path = "/welcome") String home(@RequestHeader HttpHeaders headers); @GetMapping(value = "/stations") HttpEntity query(@RequestHeader HttpHeaders headers); @PostMapping(value = "/stations") ResponseEntity<Response> create(@RequestBody Station station, @RequestHeader HttpHeaders headers); @PutMapping(value = "/stations") HttpEntity update(@RequestBody Station station, @RequestHeader HttpHeaders headers); @DeleteMapping(value = "/stations") ResponseEntity<Response> delete(@RequestBody Station station, @RequestHeader HttpHeaders headers); @GetMapping(value = "/stations/id/{stationNameForId}") HttpEntity queryForStationId(@PathVariable(value = "stationNameForId")
                                                String stationName, @RequestHeader HttpHeaders headers); @CrossOrigin(origins = "*") @PostMapping(value = "/stations/idlist") HttpEntity queryForIdBatch(@RequestBody List<String> stationNameList, @RequestHeader HttpHeaders headers); @CrossOrigin(origins = "*") @GetMapping(value = "/stations/name/{stationIdForName}") HttpEntity queryById(@PathVariable(value = "stationIdForName")
                                        String stationId, @RequestHeader HttpHeaders headers); @CrossOrigin(origins = "*") @PostMapping(value = "/stations/namelist") HttpEntity queryForNameBatch(@RequestBody List<String> stationIdList, @RequestHeader HttpHeaders headers);  }### Answer:
@Test public void testDelete() throws Exception { Station station = new Station(); Mockito.when(stationService.delete(Mockito.any(Station.class), Mockito.any(HttpHeaders.class))).thenReturn(response); String requestJson = JSONObject.toJSONString(station); String result = mockMvc.perform(MockMvcRequestBuilders.delete("/api/v1/stationservice/stations").contentType(MediaType.APPLICATION_JSON).content(requestJson)) .andExpect(MockMvcResultMatchers.status().isOk()) .andReturn().getResponse().getContentAsString(); Assert.assertEquals(response, JSONObject.parseObject(result, Response.class)); }