From b0f8ace89c79dc2daee0f6889dbc3889f56ad6cb Mon Sep 17 00:00:00 2001 From: Marcos Paulo de Souza Date: Fri, 23 Jul 2021 15:18:00 -0300 Subject: [PATCH] btrfs: source common/module when requiring module reload 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 Reviewed-by: Eryu Guan Signed-off-by: Eryu Guan --- 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.30.2