private long MonitorSingleStageExecution(ProgressExecutionMonitor progressExecutionMonitor, Configuration config) { progressExecutionMonitor.Start(Execution(0, config)); long total = progressExecutionMonitor.Total(); long part = total / 10; for (int i = 0; i < 9; i++) { progressExecutionMonitor.Check(Execution(part * (i + 1), config)); assertTrue(progressExecutionMonitor.Progress < total); } progressExecutionMonitor.Done(true, 0, "Test"); return(total); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void progressOnMultipleExecutions() public virtual void ProgressOnMultipleExecutions() { Configuration config = config(); ProgressExecutionMonitor progressExecutionMonitor = new ProgressExecutionMonitor(this, BatchSize, config); long total = progressExecutionMonitor.Total(); for (int i = 0; i < 4; i++) { progressExecutionMonitor.Start(Execution(0, config)); progressExecutionMonitor.Check(Execution(total / 4, config)); } progressExecutionMonitor.Done(true, 0, "Completed"); assertEquals("Each item should be completed", total, progressExecutionMonitor.Progress); }