Nir Soffer has posted comments on this change. Change subject: tests: Fix loop device leak in mount tests ......................................................................
Patch Set 1: (1 comment) https://gerrit.ovirt.org/#/c/51614/1/tests/mountTests.py File tests/mountTests.py: Line 134: finally: Line 135: m.umount(force=True, freeloop=True) Line 136: # TODO: Use libudev to wait for specific event Line 137: with stopwatch("Wait for udev events"): Line 138: udevadm.settle(5) > Note that this wait is not good enough. When running this test 500 times (u Using pyudev, we get this event when unmounting a loop device: >>> import pyudev >>> mon = pyudev.Monitor.from_netlink(pyudev.Context()) >>> mon.filter_by('block', device_type='disk') >>> mon.start() >>> for device in iter(mon.poll, None): ... pprint.pprint(device.items()) [(u'ACTION', u'change'), (u'DEVNAME', u'/dev/loop0'), (u'DEVPATH', u'/devices/virtual/block/loop0'), (u'DEVTYPE', u'disk'), (u'MAJOR', u'7'), (u'MINOR', u'0'), (u'MPATH_SBIN_PATH', u'/sbin'), (u'SEQNUM', u'12382'), (u'SUBSYSTEM', u'block'), (u'SYSTEMD_READY', u'0'), (u'TAGS', u':systemd:'), (u'USEC_INITIALIZED', u'4108524528')] Line 139: Line 140: def testSymlinkMount(self): Line 141: checkSudo(["mount", "-o", "loop", "somefile", "target"]) Line 142: checkSudo(["umount", "target"]) -- To view, visit https://gerrit.ovirt.org/51614 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iada8f3d962778c53ada4a6f0a7f3e75b80c07239 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Edward Haas <[email protected]> Gerrit-Reviewer: Fabian Deutsch <[email protected]> Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer <[email protected]> Gerrit-Reviewer: Yaniv Bronhaim <[email protected]> Gerrit-Reviewer: gerrit-hooks <[email protected]> Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
