From d99615284a83452c019f5bed05a882f93a4ef19a Mon Sep 17 00:00:00 2001 From: Qu Wenruo Date: Thu, 26 Jul 2018 14:39:01 +0800 Subject: btrfs-progs: fsck-tests: Add test image to check if btrfs check reports uninitialized rescan as error Signed-off-by: Qu Wenruo Signed-off-by: David Sterba --- .../035-rescan-not-kicked-in/no_rescan_kicked_in.img | Bin 0 -> 3072 bytes tests/fsck-tests/035-rescan-not-kicked-in/test.sh | 17 +++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 tests/fsck-tests/035-rescan-not-kicked-in/no_rescan_kicked_in.img create mode 100755 tests/fsck-tests/035-rescan-not-kicked-in/test.sh diff --git a/tests/fsck-tests/035-rescan-not-kicked-in/no_rescan_kicked_in.img b/tests/fsck-tests/035-rescan-not-kicked-in/no_rescan_kicked_in.img new file mode 100644 index 00000000..b855a72f Binary files /dev/null and b/tests/fsck-tests/035-rescan-not-kicked-in/no_rescan_kicked_in.img differ diff --git a/tests/fsck-tests/035-rescan-not-kicked-in/test.sh b/tests/fsck-tests/035-rescan-not-kicked-in/test.sh new file mode 100755 index 00000000..82fa978e --- /dev/null +++ b/tests/fsck-tests/035-rescan-not-kicked-in/test.sh @@ -0,0 +1,17 @@ +#!/bin/bash +# Under certain power loss case, btrfs quota tree can be initialized but +# rescan not kicked in. Can be also reproduced by fstests/btrfs/166 but with +# low probability. +# +# This test case verifies a special case when 'btrfs check' does not report +# qgroup accounting differece as an error, thus no false alert for btrfs/166. + +source "$TEST_TOP/common" + +check_prereq btrfs + +check_image() { + run_check "$TOP/btrfs" check "$1" +} + +check_all_images -- cgit v1.2.3