[PATCH] btrfs: Source common/module when requiring module reload

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]



Tests 163, 219, 225 and 242 require the btrfs module to be reloaded in
the middle of the test. If btrfs is compiled builtin, these tests
should be skipped, since we cannot unload it.

Today, this is what happens:

    QA output created by 242
    +./common/btrfs: line 405: _require_loadable_fs_module: command not found

Sourcing common/module in these tests fixes the issue by skipping the
test:
    btrfs/242       [not run] btrfs: must be a module.
    Ran: btrfs/242
    Not run: btrfs/242

Other tests liker btrfs/124 and btrfs/125 already source the same file
for the same reason, so follow the pattern.

Signed-off-by: Marcos Paulo de Souza <mpdesouza@xxxxxxxx>
---
 tests/btrfs/163 | 1 +
 tests/btrfs/219 | 1 +
 tests/btrfs/225 | 1 +
 tests/btrfs/242 | 1 +
 4 files changed, 4 insertions(+)

diff --git a/tests/btrfs/163 b/tests/btrfs/163
index 1dc081f1..76553831 100755
--- a/tests/btrfs/163
+++ b/tests/btrfs/163
@@ -27,6 +27,7 @@ _cleanup()
 # Import common functions.
 . ./common/filter
 . ./common/filter.btrfs
+. ./common/module
 
 # real QA test starts here
 
diff --git a/tests/btrfs/219 b/tests/btrfs/219
index 528175b8..1cd5daae 100755
--- a/tests/btrfs/219
+++ b/tests/btrfs/219
@@ -35,6 +35,7 @@ _cleanup()
 
 # Import common functions.
 . ./common/filter
+. ./common/module
 
 # real QA test starts here
 
diff --git a/tests/btrfs/225 b/tests/btrfs/225
index 408c03d2..ce1818db 100755
--- a/tests/btrfs/225
+++ b/tests/btrfs/225
@@ -25,6 +25,7 @@ _cleanup()
 
 # Import common functions.
 . ./common/filter
+. ./common/module
 
 # real QA test starts here
 
diff --git a/tests/btrfs/242 b/tests/btrfs/242
index 6ce62081..e1c102ae 100755
--- a/tests/btrfs/242
+++ b/tests/btrfs/242
@@ -13,6 +13,7 @@ _begin_fstest auto quick volume trim
 
 # Import common functions.
 . ./common/filter
+. ./common/module
 
 # real QA test starts here
 _supported_fs btrfs
-- 
2.26.2




[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux