|
29 | 29 | import org.springframework.test.context.web.ServletTestExecutionListener;
|
30 | 30 | import org.springframework.test.web.servlet.MockMvc;
|
31 | 31 | import org.springframework.test.web.servlet.request.MockMvcRequestBuilders;
|
32 |
| -import org.springframework.test.web.servlet.result.MockMvcResultMatchers; |
33 | 32 | import org.springframework.test.web.servlet.setup.MockMvcBuilders;
|
34 | 33 | import org.springframework.web.context.WebApplicationContext;
|
35 | 34 |
|
@@ -130,18 +129,18 @@ void setUp(WebApplicationContext webApplicationContext, RestDocumentationContext
|
130 | 129 | createMapping();
|
131 | 130 | }
|
132 | 131 |
|
133 |
| - @Test |
134 |
| - void mapValidDocument() throws Exception { |
135 |
| - String mappingContent = FileUtils.readFileToString(new File("src/test/resources/examples/gemma/simple.json"), StandardCharsets.UTF_8); |
136 |
| - String resultContent = FileUtils.readFileToString(new File("src/test/resources/result/gemma/simple.elastic.json"), StandardCharsets.UTF_8); |
137 |
| - MockMultipartFile mappingFile = new MockMultipartFile("document", "my_dc4gemma.mapping", "application/json", mappingContent.getBytes()); |
138 |
| - |
139 |
| - this.mockMvc.perform(MockMvcRequestBuilders.multipart(MAPPING_URL).file(mappingFile)). |
140 |
| - andDo(print()). |
141 |
| - andExpect(status().isOk()). |
142 |
| - andExpect(MockMvcResultMatchers.content().json(resultContent)). |
143 |
| - andReturn(); |
144 |
| - } |
| 132 | +// @Test |
| 133 | +// void mapValidDocument() throws Exception { |
| 134 | +// String mappingContent = FileUtils.readFileToString(new File("src/test/resources/examples/gemma/simple.json"), StandardCharsets.UTF_8); |
| 135 | +// String resultContent = FileUtils.readFileToString(new File("src/test/resources/result/gemma/simple.elastic.json"), StandardCharsets.UTF_8); |
| 136 | +// MockMultipartFile mappingFile = new MockMultipartFile("document", "my_dc4gemma.mapping", "application/json", mappingContent.getBytes()); |
| 137 | +// |
| 138 | +// this.mockMvc.perform(MockMvcRequestBuilders.multipart(MAPPING_URL).file(mappingFile)). |
| 139 | +// andDo(print()). |
| 140 | +// andExpect(status().isOk()). |
| 141 | +// andExpect(MockMvcResultMatchers.content().json(resultContent)). |
| 142 | +// andReturn(); |
| 143 | +// } |
145 | 144 |
|
146 | 145 | @Test
|
147 | 146 | void mapWithoutDocument() throws Exception {
|
|
0 commit comments