diff --git a/qubes/storage/lvm.py b/qubes/storage/lvm.py index aab81667..99a89f47 100644 --- a/qubes/storage/lvm.py +++ b/qubes/storage/lvm.py @@ -509,7 +509,7 @@ class ThinVolume(qubes.storage.Volume): # HACK: neat trick to speed up testing if you have same physical thin # pool assigned to two qubes-pools i.e: qubes_dom0 and test-lvm # pylint: disable=line-too-long - if isinstance(src_volume.pool, ThinPool) and \ + if hasattr(src_volume.pool, 'thin_pool') and \ src_volume.pool.thin_pool == self.pool.thin_pool: # NOQA yield from self._commit(src_volume.path[len('/dev/'):], keep=True) else: diff --git a/qubes/tests/storage_lvm.py b/qubes/tests/storage_lvm.py index 2d1d1e69..aa11fcd2 100644 --- a/qubes/tests/storage_lvm.py +++ b/qubes/tests/storage_lvm.py @@ -792,8 +792,7 @@ class TC_00_ThinPool(ThinPoolBase): # also should be different than source volume (clone, not the same LV) self.assertNotEqual(uuid_after, source_uuid) - if VOLUME_CLASS == ThinVolume: - self.assertEqual(self._get_lv_origin_uuid(volume.path), source_uuid) + self.assertEqual(self._get_lv_origin_uuid(volume.path), source_uuid) expected_revisions = { '1521065906-back': '2018-03-14T22:18:26',