Examples of StepExecution


Examples of org.springframework.batch.core.StepExecution

  }

  @Test
  public void testGetDurationWithRunningExecution() {
    assertEquals(0, history.getCount());
    StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution();
    stepExecution.setStartTime(new Date(System.currentTimeMillis()-1000));
    history.append(stepExecution);
    assertEquals("Incomplete history should have no duration: "+history.getDuration(), 0, history.getDuration().getMean(), 0.01);
  }
View Full Code Here

Examples of org.springframework.batch.core.StepExecution

  }

  @Test
  public void testGetCountWithCompletedExecution() {
    assertEquals(0, history.getCount());
    StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution();
    stepExecution.setEndTime(new Date());
    history.append(stepExecution);
    assertEquals(1, history.getCount());
  }
View Full Code Here

Examples of org.springframework.batch.core.StepExecution

  @Qualifier("jobs/executions/steps")
  private View view;

  @Test
  public void testLaunchViewWithStepExecutions() throws Exception {
    StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution();
    model.put("stepExecutions", Arrays.asList(new StepExecutionInfo(stepExecution, TimeZone.getTimeZone("GMT"))));
    model.put("jobExecutionInfo",
        new JobExecutionInfo(stepExecution.getJobExecution(), TimeZone.getTimeZone("GMT")));
    view.render(model, request, response);
    String content = response.getContentAsString();
    // System.err.println(content);
    assertTrue(content.contains("Step Executions"));
    assertTrue(content.contains("for Job = job"));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.