Copilot commented on code in PR #10686:
URL: https://github.com/apache/cloudstack/pull/10686#discussion_r2036822309


##########
plugins/hypervisors/kvm/src/test/java/com/cloud/hypervisor/kvm/resource/wrapper/LibvirtMigrateCommandWrapperTest.java:
##########
@@ -704,7 +704,7 @@ private void 
configureAndVerifyTestSearchDiskDefOnMigrateDiskInfoList(String ser
 
     @Test
     public void deleteOrDisconnectDisksOnSourcePoolTest() {
-        LibvirtMigrateCommandWrapper spyLibvirtMigrateCmdWrapper = 
Mockito.spy(libvirtMigrateCmdWrapper);
+        LibvirtMigrateCommandWrapper spyLibvirtMigrateCmdWrapper = 
libvirtMigrateCmdWrapper;
         
Mockito.doNothing().when(spyLibvirtMigrateCmdWrapper).deleteLocalVolume("volPath");

Review Comment:
   [nitpick] The redundant spy wrapping is unnecessary since 
libvirtMigrateCmdWrapper is already a spy. Removing this redundant wrapping can 
simplify the test code.
   ```suggestion
           
Mockito.doNothing().when(libvirtMigrateCmdWrapper).deleteLocalVolume("volPath");
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to