@Test
	public void testCreatedUndeployedJobIsExposedAsUndeployed() throws Exception {
		mockMvc.perform(
				post("/jobs/definitions").param("name", "job1").param("definition", JOB_DEFINITION).param("deploy",
						"false")
						.accept(MediaType.APPLICATION_JSON)).andExpect(status().isCreated());

		mockMvc.perform(get("/jobs/definitions/job1")
				.accept(MediaType.APPLICATION_JSON))
				.andExpect(status().isOk())
				.andExpect(jsonPath("$.status", equalTo(DeploymentUnitStatus.State.undeployed.toString())));

	}
Tests REST compliance of jobs-related endpoints.

@author Glenn Renfro
@author Ilayaperumal Gopinathan
@author Mark Fisher
@author Florent Biville
spring-xd-dirt/src/test/java/org/springframework/xd/dirt/rest/JobsControllerIntegrationTests.java