f37345
From 9618b84f94187efddc7316c2546bed923a91ecf9 Mon Sep 17 00:00:00 2001
f37345
From: Vojtech Trefny <vtrefny@redhat.com>
f37345
Date: Thu, 3 Nov 2022 08:36:27 +0100
f37345
Subject: [PATCH 1/2] Revert "Set XFS minimal size to 300 MiB"
f37345
f37345
This reverts commit 307d49833771d161314bae50c68e70dc35c3bb36.
f37345
---
f37345
 blivet/formats/fs.py | 2 +-
f37345
 1 file changed, 1 insertion(+), 1 deletion(-)
f37345
f37345
diff --git a/blivet/formats/fs.py b/blivet/formats/fs.py
f37345
index 8c346aa5..33922f3a 100644
f37345
--- a/blivet/formats/fs.py
f37345
+++ b/blivet/formats/fs.py
f37345
@@ -1091,7 +1091,7 @@ class XFS(FS):
f37345
     _modules = ["xfs"]
f37345
     _labelfs = fslabeling.XFSLabeling()
f37345
     _uuidfs = fsuuid.XFSUUID()
f37345
-    _min_size = Size("300 MiB")
f37345
+    _min_size = Size("16 MiB")
f37345
     _max_size = Size("16 EiB")
f37345
     _formattable = True
f37345
     _linux_native = True
f37345
-- 
f37345
2.38.1
f37345
f37345
f37345
From 24d94922d6879baa85aaa101f6b21efa568a9cbc Mon Sep 17 00:00:00 2001
f37345
From: Vojtech Trefny <vtrefny@redhat.com>
f37345
Date: Thu, 3 Nov 2022 08:36:39 +0100
f37345
Subject: [PATCH 2/2] Revert "tests: Create bigger devices for XFS testing"
f37345
f37345
This reverts commit 467cb8024010b2cabb1e92d9e64f6d3cbe949ad9.
f37345
---
f37345
 tests/storage_tests/formats_test/fs_test.py       | 7 +++----
f37345
 tests/storage_tests/formats_test/fslabeling.py    | 4 +---
f37345
 tests/storage_tests/formats_test/fsuuid.py        | 4 +---
f37345
 tests/storage_tests/formats_test/labeling_test.py | 2 --
f37345
 tests/storage_tests/formats_test/uuid_test.py     | 3 ---
f37345
 5 files changed, 5 insertions(+), 15 deletions(-)
f37345
f37345
diff --git a/tests/storage_tests/formats_test/fs_test.py b/tests/storage_tests/formats_test/fs_test.py
f37345
index cf8fb441..97f4cbbe 100644
f37345
--- a/tests/storage_tests/formats_test/fs_test.py
f37345
+++ b/tests/storage_tests/formats_test/fs_test.py
f37345
@@ -54,7 +54,6 @@ class ReiserFSTestCase(fstesting.FSAsRoot):
f37345
 
f37345
 class XFSTestCase(fstesting.FSAsRoot):
f37345
     _fs_class = fs.XFS
f37345
-    _DEVICE_SIZE = Size("500 MiB")
f37345
 
f37345
     def can_resize(self, an_fs):
f37345
         resize_tasks = (an_fs._resize, an_fs._size_info)
f37345
@@ -96,12 +95,12 @@ class XFSTestCase(fstesting.FSAsRoot):
f37345
             self.assertFalse(an_fs.resizable)
f37345
             # Not resizable, so can not do resizing actions.
f37345
             with self.assertRaises(DeviceFormatError):
f37345
-                an_fs.target_size = Size("300 MiB")
f37345
+                an_fs.target_size = Size("64 MiB")
f37345
             with self.assertRaises(DeviceFormatError):
f37345
                 an_fs.do_resize()
f37345
         else:
f37345
             disk = DiskDevice(os.path.basename(self.loop_devices[0]))
f37345
-            part = self._create_partition(disk, Size("300 MiB"))
f37345
+            part = self._create_partition(disk, Size("50 MiB"))
f37345
             an_fs = self._fs_class()
f37345
             an_fs.device = part.path
f37345
             self.assertIsNone(an_fs.create())
f37345
@@ -114,7 +113,7 @@ class XFSTestCase(fstesting.FSAsRoot):
f37345
             part = self._create_partition(disk, size=part.size + Size("40 MiB"))
f37345
 
f37345
             # Try a reasonable target size
f37345
-            TARGET_SIZE = Size("325 MiB")
f37345
+            TARGET_SIZE = Size("64 MiB")
f37345
             an_fs.target_size = TARGET_SIZE
f37345
             self.assertEqual(an_fs.target_size, TARGET_SIZE)
f37345
             self.assertNotEqual(an_fs._size, TARGET_SIZE)
f37345
diff --git a/tests/storage_tests/formats_test/fslabeling.py b/tests/storage_tests/formats_test/fslabeling.py
f37345
index ebe0b70a..0e0dc261 100644
f37345
--- a/tests/storage_tests/formats_test/fslabeling.py
f37345
+++ b/tests/storage_tests/formats_test/fslabeling.py
f37345
@@ -21,10 +21,8 @@ class LabelingAsRoot(loopbackedtestcase.LoopBackedTestCase):
f37345
     _invalid_label = abc.abstractproperty(
f37345
         doc="A label which is invalid for this filesystem.")
f37345
 
f37345
-    _DEVICE_SIZE = Size("100 MiB")
f37345
-
f37345
     def __init__(self, methodName='run_test'):
f37345
-        super(LabelingAsRoot, self).__init__(methodName=methodName, device_spec=[self._DEVICE_SIZE])
f37345
+        super(LabelingAsRoot, self).__init__(methodName=methodName, device_spec=[Size("100 MiB")])
f37345
 
f37345
     def setUp(self):
f37345
         an_fs = self._fs_class()
f37345
diff --git a/tests/storage_tests/formats_test/fsuuid.py b/tests/storage_tests/formats_test/fsuuid.py
f37345
index 0b9762fd..16aa19a6 100644
f37345
--- a/tests/storage_tests/formats_test/fsuuid.py
f37345
+++ b/tests/storage_tests/formats_test/fsuuid.py
f37345
@@ -23,11 +23,9 @@ class SetUUID(loopbackedtestcase.LoopBackedTestCase):
f37345
     _invalid_uuid = abc.abstractproperty(
f37345
         doc="An invalid UUID for this filesystem.")
f37345
 
f37345
-    _DEVICE_SIZE = Size("100 MiB")
f37345
-
f37345
     def __init__(self, methodName='run_test'):
f37345
         super(SetUUID, self).__init__(methodName=methodName,
f37345
-                                      device_spec=[self._DEVICE_SIZE])
f37345
+                                      device_spec=[Size("100 MiB")])
f37345
 
f37345
     def setUp(self):
f37345
         an_fs = self._fs_class()
f37345
diff --git a/tests/storage_tests/formats_test/labeling_test.py b/tests/storage_tests/formats_test/labeling_test.py
f37345
index 0702260a..d24e6619 100644
f37345
--- a/tests/storage_tests/formats_test/labeling_test.py
f37345
+++ b/tests/storage_tests/formats_test/labeling_test.py
f37345
@@ -1,7 +1,6 @@
f37345
 import unittest
f37345
 
f37345
 from blivet.formats import device_formats
f37345
-from blivet.size import Size
f37345
 import blivet.formats.fs as fs
f37345
 import blivet.formats.swap as swap
f37345
 
f37345
@@ -62,7 +61,6 @@ class InitializationTestCase(unittest.TestCase):
f37345
 class XFSTestCase(fslabeling.CompleteLabelingAsRoot):
f37345
     _fs_class = fs.XFS
f37345
     _invalid_label = "root filesystem"
f37345
-    _DEVICE_SIZE = Size("500 MiB")
f37345
 
f37345
 
f37345
 class FATFSTestCase(fslabeling.CompleteLabelingAsRoot):
f37345
diff --git a/tests/storage_tests/formats_test/uuid_test.py b/tests/storage_tests/formats_test/uuid_test.py
f37345
index af35c0ee..ee8d452e 100644
f37345
--- a/tests/storage_tests/formats_test/uuid_test.py
f37345
+++ b/tests/storage_tests/formats_test/uuid_test.py
f37345
@@ -2,7 +2,6 @@ import unittest
f37345
 
f37345
 import blivet.formats.fs as fs
f37345
 import blivet.formats.swap as swap
f37345
-from blivet.size import Size
f37345
 
f37345
 from . import fsuuid
f37345
 
f37345
@@ -53,14 +52,12 @@ class XFSTestCase(fsuuid.SetUUIDWithMkFs):
f37345
     _fs_class = fs.XFS
f37345
     _invalid_uuid = "abcdefgh-ijkl-mnop-qrst-uvwxyz123456"
f37345
     _valid_uuid = "97e3d40f-dca8-497d-8b86-92f257402465"
f37345
-    _DEVICE_SIZE = Size("500 MiB")
f37345
 
f37345
 
f37345
 class XFSAfterTestCase(fsuuid.SetUUIDAfterMkFs):
f37345
     _fs_class = fs.XFS
f37345
     _invalid_uuid = "abcdefgh-ijkl-mnop-qrst-uvwxyz123456"
f37345
     _valid_uuid = "97e3d40f-dca8-497d-8b86-92f257402465"
f37345
-    _DEVICE_SIZE = Size("500 MiB")
f37345
 
f37345
 
f37345
 class FATFSTestCase(fsuuid.SetUUIDWithMkFs):
f37345
-- 
f37345
2.38.1
f37345