- final ListenableFuture<Instruction> future = this.testedProgrammingService.scheduleInstruction(mockedSubmit1);
-
- final SubmitInstructionInput mockedSubmit2 = getMockedSubmitInstructionInput("mockedSubmit2", "mockedSubmit1");
- final ListenableFuture<Instruction> future2 = this.testedProgrammingService.scheduleInstruction(mockedSubmit2);
-
- this.mockedNotificationServiceWrapper.assertNotificationsCount(1);
-
- Instruction i = future.get();
- i.checkedExecutionStart();
- i.executionCompleted(InstructionStatus.Successful, getDetails());
-
- this.mockedNotificationServiceWrapper.assertNotificationsCount(4);
- this.mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(1, mockedSubmit1.getId(), InstructionStatus.Executing);
- this.mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(2, mockedSubmit1.getId(), InstructionStatus.Successful);
- this.mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(3, mockedSubmit2.getId(), InstructionStatus.Scheduled);
-
- i = future2.get();
- i.checkedExecutionStart();
- i.executionCompleted(InstructionStatus.Successful, getDetails());
-
- this.mockedNotificationServiceWrapper.assertNotificationsCount(6);
- this.mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(4, mockedSubmit2.getId(), InstructionStatus.Executing);
- this.mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(5, mockedSubmit2.getId(), InstructionStatus.Successful);
+ final ListenableFuture<Instruction> future = testedProgrammingService.scheduleInstruction(mockedSubmit1);
+
+ final SubmitInstructionInput mockedSubmit2 =
+ getMockedSubmitInstructionInput("mockedSubmit2", "mockedSubmit1");
+ final ListenableFuture<Instruction> future2 = testedProgrammingService.scheduleInstruction(mockedSubmit2);
+
+ mockedNotificationServiceWrapper.assertNotificationsCount(1);
+
+ Instruction instruction = future.get();
+ instruction.checkedExecutionStart();
+ instruction.executionCompleted(InstructionStatus.Successful, getDetails());
+
+ mockedNotificationServiceWrapper.assertNotificationsCount(4);
+ mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(1, mockedSubmit1.getId(),
+ InstructionStatus.Executing);
+ mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(2, mockedSubmit1.getId(),
+ InstructionStatus.Successful);
+ mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(3, mockedSubmit2.getId(),
+ InstructionStatus.Scheduled);
+
+ instruction = future2.get();
+ instruction.checkedExecutionStart();
+ instruction.executionCompleted(InstructionStatus.Successful, getDetails());
+
+ mockedNotificationServiceWrapper.assertNotificationsCount(6);
+ mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(4, mockedSubmit2.getId(),
+ InstructionStatus.Executing);
+ mockedNotificationServiceWrapper.assertInstructionStatusChangedNotification(5, mockedSubmit2.getId(),
+ InstructionStatus.Successful);