summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorEryu Guan <eguan@redhat.com>2016-12-05 00:15:08 +0800
committerEryu Guan <eguan@redhat.com>2016-12-19 10:34:49 +0800
commit596a068bf130d5430b9078923b28ab5263e98d73 (patch)
tree98e113aa087d525195e4bb5560bf74b5a2fe5747 /tests
parentc1cd6b1d57e1e47e626dd771d1697937414002ac (diff)
fstests: teach _scratch_mkfs to handle mkfs option conflicts
Currently in _scratch_mkfs only xfs and ext4 could handle the mkfs failure caused by conflicts between $MKFS_OPTIONS and mkfs options specified by tests, because of _scratch_mkfs_xfs and _scratch_mkfs_ext4. This is a very useful functionality that allows tests to specify mkfs options safely and to test specific fs configurations, without worrying about mkfs failures caused by these options. Now teach _scratch_mkfs to handle such mkfs option conflicts for other filesystems too, i.e. mkfs again only with mkfs options specified by tests. Also add the ability to filter unnecessary messages from mkfs stderr. Also update some btrfs tests to throw away _scratch_mkfs stdout, because previously _scratch_mkfs did this for btrfs. Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Eryu Guan <eguan@redhat.com>
Diffstat (limited to 'tests')
-rwxr-xr-xtests/btrfs/0282
-rwxr-xr-xtests/btrfs/1212
-rwxr-xr-xtests/btrfs/1222
-rwxr-xr-xtests/btrfs/1232
-rwxr-xr-xtests/btrfs/1262
5 files changed, 5 insertions, 5 deletions
diff --git a/tests/btrfs/028 b/tests/btrfs/028
index a3d9a271..0e626720 100755
--- a/tests/btrfs/028
+++ b/tests/btrfs/028
@@ -53,7 +53,7 @@ _supported_os Linux
_require_scratch
_require_btrfs_qgroup_report
-_scratch_mkfs
+_scratch_mkfs >/dev/null
_scratch_mount
_run_btrfs_util_prog quota enable $SCRATCH_MNT
diff --git a/tests/btrfs/121 b/tests/btrfs/121
index 011c5a88..5a73235d 100755
--- a/tests/btrfs/121
+++ b/tests/btrfs/121
@@ -56,7 +56,7 @@ _require_scratch
rm -f $seqres.full
-_scratch_mkfs
+_scratch_mkfs >/dev/null
_scratch_mount
_run_btrfs_util_prog quota enable $SCRATCH_MNT
# The qgroup '1/10' does not exist and should be silently ignored
diff --git a/tests/btrfs/122 b/tests/btrfs/122
index 6a7f17f2..213a27f8 100755
--- a/tests/btrfs/122
+++ b/tests/btrfs/122
@@ -55,7 +55,7 @@ rm -f $seqres.full
# Force a small leaf size to make it easier to blow out our root
# subvolume tree
-_scratch_mkfs "--nodesize 16384"
+_scratch_mkfs "--nodesize 16384" >/dev/null
_scratch_mount
_run_btrfs_util_prog quota enable $SCRATCH_MNT
diff --git a/tests/btrfs/123 b/tests/btrfs/123
index 52d87fbb..4b2e667f 100755
--- a/tests/btrfs/123
+++ b/tests/btrfs/123
@@ -55,7 +55,7 @@ _supported_os Linux
_require_scratch
_require_btrfs_qgroup_report
-_scratch_mkfs
+_scratch_mkfs >/dev/null
# Need to use inline extents to fill metadata rapidly
_scratch_mount "-o max_inline=2048"
diff --git a/tests/btrfs/126 b/tests/btrfs/126
index c06c00b4..372236ff 100755
--- a/tests/btrfs/126
+++ b/tests/btrfs/126
@@ -51,7 +51,7 @@ _supported_os Linux
_require_scratch
_require_btrfs_qgroup_report
-_scratch_mkfs
+_scratch_mkfs >/dev/null
# Use enospc_debug mount option to trigger restrict space info check
_scratch_mount "-o enospc_debug"