Vered Volansky has posted comments on this change. Change subject: core: ImportVm test cleanup: VM name generation ......................................................................
Patch Set 10: (2 inline comments) .................................................... File backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/ImportVmCommandTest.java Line 108: */ Line 109: @Test Line 110: public void testOtherFieldsNotValidatedInImport() { Line 111: ImportVmParameters parameters = createParameters(); Line 112: String stringOf5000Chars = Please correct me if I'm wrong, but the generated string is of size GENERAL_MAX_SIZE, which doesn't have to be 5000 (and is actually 4000 according to my check, though it doesn't matter). Line 113: RandomUtils.instance().nextNameString(BusinessEntitiesDefinitions.GENERAL_MAX_SIZE + 1); Line 114: parameters.getVm().setUserDefinedProperties(stringOf5000Chars); Line 115: parameters.setImportAsNewEntity(true); Line 116: ImportVmCommand command = new ImportVmCommand(parameters); .................................................... File backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/RandomUtils.java Line 368: * Line 369: * @param length Line 370: * The requested length of the string. Line 371: */ Line 372: public String nextNameString(int length) { I don't get the naming of this method (I get that overloading is taken, but this name doesn't seem right). I also don't get the naming of the new constant. The returned string isn't being used as a name, specifically not in this patch, and even if it were, this class shouldn't know about the uses. Line 373: return nextString(length, ENTITY_NAME_CHARS); Line 374: } Line 375: Line 376: /** -- To view, visit http://gerrit.ovirt.org/9619 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I1f04e067e8bce2c6cd1010f83a44809a3c8c464c Gerrit-PatchSet: 10 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Allon Mureinik <amure...@redhat.com> Gerrit-Reviewer: Alissa Bonas <abo...@redhat.com> Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com> Gerrit-Reviewer: Ayal Baron <aba...@redhat.com> Gerrit-Reviewer: Daniel Erez <de...@redhat.com> Gerrit-Reviewer: Liron Aravot <lara...@redhat.com> Gerrit-Reviewer: Maor Lipchuk <mlipc...@redhat.com> Gerrit-Reviewer: Vered Volansky <vvola...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches