Frank Kobzik has uploaded a new change for review. Change subject: core: hotfix daotests in VmStaticDAOTest ......................................................................
core: hotfix daotests in VmStaticDAOTest testGetOrderedVmGuidsForRunMultipleActionsByMigrationSupport which tested db logic for ordered VmGuids retrieval (with respect to MigrationSupport attribute) was failing because the number of tested vms was 4, but MigrationSupport has only 3 possible values. Therefore there were 2 VMs that were equal with respect to this ordering. Hot-fixed by restricting the number of test VMs to 3. Change-Id: I0ea611effabb69a693194a6a0639f2d3c17d08e5 Signed-off-by: Frantisek Kobzik <[email protected]> --- M backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/VmStaticDAOTest.java 1 file changed, 3 insertions(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/14/35914/1 diff --git a/backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/VmStaticDAOTest.java b/backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/VmStaticDAOTest.java index 9f02c5b..3cb8793 100644 --- a/backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/VmStaticDAOTest.java +++ b/backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/VmStaticDAOTest.java @@ -327,6 +327,9 @@ @Test public void testGetOrderedVmGuidsForRunMultipleActionsByMigrationSupport() { List<VmStatic> vmStatics = dao.getAllByName(STATIC_VM_NAME); + if (vmStatics.size() > 3) { // migration support has only 3 possible values + vmStatics = vmStatics.subList(0, 3); + } VmStatic[] vmStaticArrayInDescOrder = initVmStaticsOrderedByMigrationSupport(vmStatics); // execute -- To view, visit http://gerrit.ovirt.org/35914 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I0ea611effabb69a693194a6a0639f2d3c17d08e5 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Frank Kobzik <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
