@Test
	public void saveComposedModule() throws Exception {
		mockMvc.perform(post("/modules")
				.param("name", "compositesink")
				.param("definition", "processor_2 | sink_1")
				.accept(MediaType.APPLICATION_JSON))
				.andExpect(status().is(201)).andExpect(
				jsonPath("$.name").value("compositesink")).andExpect(
				jsonPath("$.type").value("sink"));

	}
Tests REST compliance of module-related endpoints.

@author Glenn Renfro
@author Mark Fisher
@author Gunnar Hillert
@author Ilayaperumal Gopinathan
spring-xd-dirt/src/test/java/org/springframework/xd/dirt/rest/ModulesControllerIntegrationTests.java