@Test public void test_getSubjectSchema() throws Exception { String subject = "ss.s"; String version = "ss"; when(kafkaSchemaService.getSubjectSchema(subject, version)) .thenReturn(null); mockMvc.perform(get(API_PATH + "/subjectSchema", subject, version) .param("subject", subject) .param("version", version)) .andExpect(status().isOk()); verify(kafkaSchemaService).getSubjectSchema(subject, version); }
@RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) public Schema getSubjectSchema(@RequestParam("subject") String subject, @RequestParam("version") String version) { return kafkaSchemaService.getSubjectSchema(subject, version); }
KafkaSchemaController { @RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) public Schema getSubjectSchema(@RequestParam("subject") String subject, @RequestParam("version") String version) { return kafkaSchemaService.getSubjectSchema(subject, version); } }
KafkaSchemaController { @RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) public Schema getSubjectSchema(@RequestParam("subject") String subject, @RequestParam("version") String version) { return kafkaSchemaService.getSubjectSchema(subject, version); }  }
KafkaSchemaController { @RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) public Schema getSubjectSchema(@RequestParam("subject") String subject, @RequestParam("version") String version) { return kafkaSchemaService.getSubjectSchema(subject, version); }  @RequestMapping(value = "/schema/{id}", method = RequestMethod.GET) SchemaString getSchemaString(@PathVariable("id") Integer id); @RequestMapping(value = "/subject", method = RequestMethod.GET) Iterable<String> getSubjects(); @RequestMapping(value = "/versions", method = RequestMethod.GET) Iterable<Integer> getSubjectVersions(
        @RequestParam("subject") String subject); @RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) Schema getSubjectSchema(@RequestParam("subject") String subject,
                                   @RequestParam("version") String version); @RequestMapping(value = "/config", method = RequestMethod.GET) Config getTopLevelConfig(); @RequestMapping(value = "/config/{subject}", method = RequestMethod.GET) Config getSubjectLevelConfig(@PathVariable("subject") String subject); }
KafkaSchemaController { @RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) public Schema getSubjectSchema(@RequestParam("subject") String subject, @RequestParam("version") String version) { return kafkaSchemaService.getSubjectSchema(subject, version); }  @RequestMapping(value = "/schema/{id}", method = RequestMethod.GET) SchemaString getSchemaString(@PathVariable("id") Integer id); @RequestMapping(value = "/subject", method = RequestMethod.GET) Iterable<String> getSubjects(); @RequestMapping(value = "/versions", method = RequestMethod.GET) Iterable<Integer> getSubjectVersions(
        @RequestParam("subject") String subject); @RequestMapping(value = "/subjectSchema", method = RequestMethod.GET) Schema getSubjectSchema(@RequestParam("subject") String subject,
                                   @RequestParam("version") String version); @RequestMapping(value = "/config", method = RequestMethod.GET) Config getTopLevelConfig(); @RequestMapping(value = "/config/{subject}", method = RequestMethod.GET) Config getSubjectLevelConfig(@PathVariable("subject") String subject);  }