Skip to content

Commit

Permalink
tests/storage_reflink: place test cases in numeric order
Browse files Browse the repository at this point in the history
  • Loading branch information
rustybird committed Feb 2, 2022
1 parent dc4f563 commit 476acd9
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions qubes/tests/storage_reflink.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,18 @@ def test_001_create_and_resize_files_and_update_loopdevs(self):
self.assertEqual(get_blockdev_size(dev), size_resized)


class TC_00_ReflinkOnBtrfs(ReflinkMixin, qubes.tests.QubesTestCase):
def setUp(self): # pylint: disable=arguments-differ
super().setUp('btrfs')
self.ficlone_supported = True


class TC_01_ReflinkOnExt4(ReflinkMixin, qubes.tests.QubesTestCase):
def setUp(self): # pylint: disable=arguments-differ
super().setUp('ext4')
self.ficlone_supported = False


class TC_10_ReflinkPool(qubes.tests.QubesTestCase):
def setUp(self):
super().setUp()
Expand Down Expand Up @@ -142,17 +154,6 @@ def test_012_import_data_empty(self):
self.assertNotEqual(volume_data, 'test data')


class TC_00_ReflinkOnBtrfs(ReflinkMixin, qubes.tests.QubesTestCase):
def setUp(self): # pylint: disable=arguments-differ
super().setUp('btrfs')
self.ficlone_supported = True

class TC_01_ReflinkOnExt4(ReflinkMixin, qubes.tests.QubesTestCase):
def setUp(self): # pylint: disable=arguments-differ
super().setUp('ext4')
self.ficlone_supported = False


def setup_loopdev(img, cleanup_via=None):
dev = str.strip(cmd('sudo', 'losetup', '-f', '--show', img).decode())
if cleanup_via is not None:
Expand Down

0 comments on commit 476acd9

Please sign in to comment.