Skip to content

add more tests

02181da
Select commit
Loading
Failed to load commit list.
Draft

CLVM enhancements and fixes #12617

add more tests
02181da
Select commit
Loading
Failed to load commit list.
SonarQubeCloud / SonarCloud Code Analysis failed Mar 31, 2026 in 5m 26s

Quality Gate failed

Annotations

Check warning on line 813 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Format specifiers should be used instead of string concatenation.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YeN4256DVCsFLrb&open=AZz35YeN4256DVCsFLrb&pullRequest=12617

Check failure on line 2389 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 19 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZxOatxGxHcHLzahJAAH&open=AZxOatxGxHcHLzahJAAH&pullRequest=12617

Check warning on line 1873 in server/src/main/java/com/cloud/storage/snapshot/SnapshotManagerImpl.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use a primitive boolean expression here.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0nMp40a7K9fovmFaCc&open=AZ0nMp40a7K9fovmFaCc&pullRequest=12617

Check failure on line 245 in plugins/hypervisors/kvm/src/test/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptorTest.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Add at least one assertion to this test case.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0mNDXNmxdebns9DnLm&open=AZ0mNDXNmxdebns9DnLm&pullRequest=12617

Check warning on line 45 in server/src/main/java/com/cloud/storage/ClvmLockManager.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this field injection and use constructor injection instead.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZycJTXm331ZRqy8rtiw&open=AZycJTXm331ZRqy8rtiw&pullRequest=12617

Check warning on line 2278 in engine/storage/datamotion/src/main/java/org/apache/cloudstack/storage/motion/StorageSystemDataMotionStrategy.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Invoke method(s) only conditionally.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz4pqxYEjiWGn0xPnaT&open=AZz4pqxYEjiWGn0xPnaT&pullRequest=12617

Check warning on line 997 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this hard-coded path-delimiter.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YeN4256DVCsFLrd&open=AZz35YeN4256DVCsFLrd&pullRequest=12617

Check warning on line 748 in server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

A "Brain Method" was detected. Refactor it to reduce at least one of the following metrics: LOC from 168 to 64, Complexity from 53 to 14, Nesting Level from 5 to 2, Number of Variables from 27 to 6.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0sIVbYlpSFCu4-z-Dn&open=AZ0sIVbYlpSFCu4-z-Dn&pullRequest=12617

Check failure on line 371 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Define a constant instead of duplicating this literal "--noheadings" 8 times.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YeN4256DVCsFLrQ&open=AZz35YeN4256DVCsFLrQ&pullRequest=12617

Check warning on line 370 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this use of "Script"; it is deprecated.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YeN4256DVCsFLrY&open=AZz35YeN4256DVCsFLrY&pullRequest=12617

Check warning on line 945 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this use of "Script"; it is deprecated.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZxEJ4RLTdhpX5MPbvmD&open=AZxEJ4RLTdhpX5MPbvmD&pullRequest=12617

Check warning on line 68 in engine/storage/src/test/java/org/apache/cloudstack/storage/endpoint/DefaultEndPointSelectorTest.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Rename this field "_volDetailsDao" to match the regular expression '^[a-z][a-zA-Z0-9]*$'.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0xehRNDDwRlMHM1FEu&open=AZ0xehRNDDwRlMHM1FEu&pullRequest=12617

Check warning on line 1154 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use the built-in formatting to construct this argument.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YY_4256DVCsFLrF&open=AZz35YY_4256DVCsFLrF&pullRequest=12617

Check failure on line 2987 in engine/storage/volume/src/main/java/org/apache/cloudstack/storage/volume/VolumeServiceImpl.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 18 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0sIU8XlpSFCu4-z-Dc&open=AZ0sIU8XlpSFCu4-z-Dc&pullRequest=12617

Check warning on line 56 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/resource/wrapper/LibvirtPrepareForMigrationCommandWrapper.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

A "Brain Method" was detected. Refactor it to reduce at least one of the following metrics: LOC from 83 to 64, Complexity from 20 to 14, Nesting Level from 5 to 2, Number of Variables from 22 to 6.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0sIVNClpSFCu4-z-Dh&open=AZ0sIVNClpSFCu4-z-Dh&pullRequest=12617

Check failure on line 277 in plugins/hypervisors/kvm/src/test/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptorTest.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Add at least one assertion to this test case.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0mNDXNmxdebns9DnLp&open=AZ0mNDXNmxdebns9DnLp&pullRequest=12617

Check warning on line 2119 in engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

A "Brain Method" was detected. Refactor it to reduce at least one of the following metrics: LOC from 79 to 64, Complexity from 21 to 14, Nesting Level from 5 to 2, Number of Variables from 25 to 6.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0sIVBclpSFCu4-z-Dg&open=AZ0sIVBclpSFCu4-z-Dg&pullRequest=12617

Check failure on line 1552 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Define a constant instead of duplicating this literal "qemu-img" 5 times.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YeN4256DVCsFLrV&open=AZz35YeN4256DVCsFLrV&pullRequest=12617

Check failure on line 800 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 21 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZxEJ4RLTdhpX5MPbvl-&open=AZxEJ4RLTdhpX5MPbvl-&pullRequest=12617

Check failure on line 311 in plugins/hypervisors/kvm/src/test/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptorTest.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Add at least one assertion to this test case.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0mNDXNmxdebns9DnLs&open=AZ0mNDXNmxdebns9DnLs&pullRequest=12617

Check warning on line 113 in server/src/test/java/com/cloud/storage/ClvmLockManagerTest.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this and every subsequent useless "eq(...)" invocation; pass the values directly.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZycJTYW331ZRqy8rtiy&open=AZycJTYW331ZRqy8rtiy&pullRequest=12617

Check warning on line 271 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Format specifiers should be used instead of string concatenation.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZxEJ4RLTdhpX5MPbvl9&open=AZxEJ4RLTdhpX5MPbvl9&pullRequest=12617

Check warning on line 2465 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this use of "Script"; it is deprecated.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZz35YeN4256DVCsFLrj&open=AZz35YeN4256DVCsFLrj&pullRequest=12617

Check warning on line 958 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Remove this hard-coded path-delimiter.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZxEJ4RLTdhpX5MPbvmE&open=AZxEJ4RLTdhpX5MPbvmE&pullRequest=12617

Check failure on line 256 in plugins/hypervisors/kvm/src/test/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptorTest.java

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Add at least one assertion to this test case.

See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ0mNDXNmxdebns9DnLn&open=AZ0mNDXNmxdebns9DnLn&pullRequest=12617