Skip to content

Commit d402fb6

Browse files
Gupta, SuryaGupta, Surya
authored andcommitted
[CSTACKEX-328] Fix Build Issue
1 parent 6cd7718 commit d402fb6

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎plugins/storage/volume/ontap/src/test/java/org/apache/cloudstack/storage/driver/OntapPrimaryDatastoreDriverTest.java‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1061,7 +1061,10 @@ void testCreateAsync_VolumeClonedFromSnapshot_IscsiWithIops_SetsQosOnLunCreate()
10611061
@Test
10621062
void testCreateAsync_VolumeClonedFromSnapshot_NfsWithIops_AttachesQosAfterClone() {
10631063
stubVolumeCloneFromSnapshot(5368709120L, 5368709120L, ProtocolType.NFS3.name());
1064+
storagePoolDetails.put(OntapStorageConstants.PROTOCOL, ProtocolType.NFS3.name());
10641065
storagePoolDetails.put(OntapStorageConstants.VOLUME_UUID, "flex-uuid");
1066+
when(storagePool.getPoolType()).thenReturn(Storage.StoragePoolType.NetworkFilesystem);
1067+
when(volumeInfo.getUuid()).thenReturn("new-volume-uuid");
10651068
when(volumeInfo.getVolumeType()).thenReturn(Volume.Type.DATADISK);
10661069
when(volumeInfo.getMinIops()).thenReturn(100L);
10671070
when(volumeInfo.getMaxIops()).thenReturn(200L);
@@ -2902,7 +2905,7 @@ private void stubResizeVolumeRecord(long currentSize) {
29022905
when(volumeVO.getId()).thenReturn(100L);
29032906
when(volumeVO.getSize()).thenReturn(currentSize);
29042907
lenient().when(volumeVO.getPath()).thenReturn("/vol/vol1/lun1");
2905-
when(volumeDao.update(100L, volumeVO)).thenReturn(true);
2908+
lenient().when(volumeDao.update(100L, volumeVO)).thenReturn(true);
29062909
when(storagePoolDao.findById(1L)).thenReturn(storagePool);
29072910
when(storagePool.getId()).thenReturn(1L);
29082911
when(storagePoolDetailsDao.listDetailsKeyPairs(1L)).thenReturn(storagePoolDetails);

0 commit comments

Comments
 (0)