@@ -3322,6 +3322,8 @@ public void testAllocateVMFromBackupUsingCmdValues() throws InsufficientCapacity
33223322 VMTemplateVO template = mock (VMTemplateVO .class );
33233323 when (template .getFormat ()).thenReturn (Storage .ImageFormat .QCOW2 );
33243324 when (templateDao .findById (templateId )).thenReturn (template );
3325+ DiskOfferingInfo rootDiskOfferingInfo = new DiskOfferingInfo (diskOffering , 10L , 1000L , 2000L );
3326+ when (backupManager .getRootDiskOfferingInfoFromBackup (backup )).thenReturn (rootDiskOfferingInfo );
33253327
33263328 Mockito .doReturn (userVmVoMock ).when (userVmManagerImpl ).createAdvancedVirtualMachine (any (), any (), any (), any (), any (), any (), any (),
33273329 any (), any (), any (), any (), any (), any (), any (), any (), any (), any (), any (), any (), nullable (Boolean .class ), any (), any (), any (),
@@ -3466,7 +3468,7 @@ public void testAllocateVMFromBackupUsingCmdValuesWithISO() throws InsufficientC
34663468 ServiceOfferingVO serviceOffering = mock (ServiceOfferingVO .class );
34673469 DiskOfferingVO rootDiskOffering = mock (DiskOfferingVO .class );
34683470 when (_serviceOfferingDao .findById (serviceOfferingId )).thenReturn (serviceOffering );
3469- when (rootDiskOffering .getDiskSize ()).thenReturn (100000000L );
3471+ when (rootDiskOffering .getDiskSize ()).thenReturn (10 * 1024 * 1024 * 1024L );
34703472 when (diskOfferingDao .findById (rootDiskOfferingId )).thenReturn (rootDiskOffering );
34713473
34723474 Map <String , String > diskDetails = new HashMap <>();
@@ -3494,6 +3496,8 @@ public void testAllocateVMFromBackupUsingCmdValuesWithISO() throws InsufficientC
34943496 VMTemplateVO iso = mock (VMTemplateVO .class );
34953497 when (iso .getFormat ()).thenReturn (Storage .ImageFormat .ISO );
34963498 when (templateDao .findById (isoId )).thenReturn (iso );
3499+ DiskOfferingInfo rootDiskOfferingInfo = new DiskOfferingInfo (diskOffering , 10L , 1000L , 2000L );
3500+ when (backupManager .getRootDiskOfferingInfoFromBackup (backup )).thenReturn (rootDiskOfferingInfo );
34973501
34983502 Mockito .doReturn (userVmVoMock ).when (userVmManagerImpl ).createAdvancedVirtualMachine (any (), any (), any (), any (), any (), any (), any (),
34993503 any (), any (), any (), any (), any (), any (), any (), any (), any (), any (), any (), any (), nullable (Boolean .class ), any (), any (), any (),
0 commit comments