@Test public void should_get_filterData() throws Exception { when(dashboardService.getMethodsFormData()).thenReturn(GetMethodsFormData.sample()); mockMvc .perform(get("/dashboard/api/v1/methodsFormData")) .andExpect(status().isOk()) .andExpect(content().contentType(APPLICATION_JSON_UTF8)) .andExpect(jsonPath("$.applications").isArray()) .andExpect(jsonPath("$.environments").isArray()) .andExpect(jsonPath("$.locations").isArray()); }
@GetMapping("/dashboard/api/v1/methodsFormData") public GetMethodsFormData getMethodsFormData() { GetMethodsFormData data = dashboardService.getMethodsFormData(); logger.debug("{}", data); return data; }
DashboardApiController { @GetMapping("/dashboard/api/v1/methodsFormData") public GetMethodsFormData getMethodsFormData() { GetMethodsFormData data = dashboardService.getMethodsFormData(); logger.debug("{}", data); return data; } }
DashboardApiController { @GetMapping("/dashboard/api/v1/methodsFormData") public GetMethodsFormData getMethodsFormData() { GetMethodsFormData data = dashboardService.getMethodsFormData(); logger.debug("{}", data); return data; }  }
DashboardApiController { @GetMapping("/dashboard/api/v1/methodsFormData") public GetMethodsFormData getMethodsFormData() { GetMethodsFormData data = dashboardService.getMethodsFormData(); logger.debug("{}", data); return data; }  @ExceptionHandler ResponseEntity<String> onConstraintValidationException(ConstraintViolationException e); @GetMapping("/dashboard/api/v1/serverSettings") ServerSettings getServerSettings(); @PostMapping("/dashboard/api/v2/methods") GetMethodsResponse2 getMethods2(@Valid @RequestBody GetMethodsRequest request); @GetMapping("/dashboard/api/v1/method/detail/{id}") ResponseEntity<MethodDescriptor1> getMethod1(@PathVariable(value = "id") Long methodId); @GetMapping("/dashboard/api/v1/status") GetStatusResponse getStatus1(); @GetMapping("/dashboard/api/v1/methodsFormData") GetMethodsFormData getMethodsFormData(); }
DashboardApiController { @GetMapping("/dashboard/api/v1/methodsFormData") public GetMethodsFormData getMethodsFormData() { GetMethodsFormData data = dashboardService.getMethodsFormData(); logger.debug("{}", data); return data; }  @ExceptionHandler ResponseEntity<String> onConstraintValidationException(ConstraintViolationException e); @GetMapping("/dashboard/api/v1/serverSettings") ServerSettings getServerSettings(); @PostMapping("/dashboard/api/v2/methods") GetMethodsResponse2 getMethods2(@Valid @RequestBody GetMethodsRequest request); @GetMapping("/dashboard/api/v1/method/detail/{id}") ResponseEntity<MethodDescriptor1> getMethod1(@PathVariable(value = "id") Long methodId); @GetMapping("/dashboard/api/v1/status") GetStatusResponse getStatus1(); @GetMapping("/dashboard/api/v1/methodsFormData") GetMethodsFormData getMethodsFormData();  }