Introduce ExecutionTimeSubject
This commit is contained in:
@ -27,7 +27,7 @@ class CommandsTests {
|
||||
EEPROMInterface eepromMock = mock(EEPROMInterface.class);
|
||||
picComponents.registerComponent(EEPROMInterface.class, eepromMock);
|
||||
|
||||
CommandInterface commands = new Commands();
|
||||
Commands commands = new Commands();
|
||||
picComponents.registerComponent(CommandInterface.class, commands);
|
||||
picComponents.initAll();
|
||||
|
||||
@ -47,7 +47,7 @@ class CommandsTests {
|
||||
EEPROMInterface eepromMock = mock(EEPROMInterface.class);
|
||||
picComponents.registerComponent(EEPROMInterface.class, eepromMock);
|
||||
|
||||
CommandInterface commands = new Commands();
|
||||
Commands commands = new Commands();
|
||||
picComponents.registerComponent(CommandInterface.class, commands);
|
||||
picComponents.initAll();
|
||||
|
||||
@ -68,7 +68,7 @@ class CommandsTests {
|
||||
EEPROMInterface eepromMock = mock(EEPROMInterface.class);
|
||||
picComponents.registerComponent(EEPROMInterface.class, eepromMock);
|
||||
|
||||
CommandInterface commands = new Commands();
|
||||
Commands commands = new Commands();
|
||||
picComponents.registerComponent(CommandInterface.class, commands);
|
||||
picComponents.initAll();
|
||||
|
||||
|
||||
@ -69,8 +69,8 @@ class EEPROMTests {
|
||||
DataRegisterInterface mockDataRegister = Mockito.mock(DataRegisterInterface.class);
|
||||
picComponents.registerComponent(DataRegisterInterface.class, mockDataRegister);
|
||||
|
||||
CommandInterface mockCommands = mock(CommandInterface.class);
|
||||
picComponents.registerComponent(CommandInterface.class, mockCommands);
|
||||
ExecutionTimeSubject mockExecutionTime = mock(ExecutionTimeSubject.class);
|
||||
picComponents.registerComponent(ExecutionTimeSubject.class, mockExecutionTime);
|
||||
|
||||
EEPROMInterface eeprom = new EEPROM();
|
||||
picComponents.registerComponent(EEPROMInterface.class, eeprom);
|
||||
|
||||
@ -29,13 +29,13 @@ class WatchDogTimerTests {
|
||||
picComponents.registerComponent(PreScalerInterface.class, mockPreScaler);
|
||||
|
||||
|
||||
CommandInterface mockCommands = mock(CommandInterface.class);
|
||||
ExecutionTimeSubject mockExecutionTime = mock(ExecutionTimeSubject.class);
|
||||
when(
|
||||
mockCommands.getExecutionTimeMultiplier()
|
||||
mockExecutionTime.getExecutionTimeMultiplier()
|
||||
).thenReturn(
|
||||
1.0
|
||||
);
|
||||
picComponents.registerComponent(CommandInterface.class, mockCommands);
|
||||
picComponents.registerComponent(ExecutionTimeSubject.class, mockExecutionTime);
|
||||
|
||||
WatchdogTimerInterface watchDogTimer = new WatchdogTimer();
|
||||
picComponents.registerComponent(WatchdogTimerInterface.class, watchDogTimer);
|
||||
|
||||
Reference in New Issue
Block a user