summaryrefslogtreecommitdiff
path: root/tests/convert-tests/012-reiserfs-large-hole-extent/test.sh
diff options
context:
space:
mode:
authorDimitri John Ledkov <xnox@ubuntu.com>2017-10-18 13:15:59 +0100
committerDimitri John Ledkov <xnox@ubuntu.com>2017-10-18 13:15:59 +0100
commit74d288e05c2d0cb97186f51049813b3e5b5bb0cd (patch)
tree4fc213398dc89e053d53ff7d42102942470e9cb5 /tests/convert-tests/012-reiserfs-large-hole-extent/test.sh
parent569a646293cd782de7665b6158514f3b48d229d3 (diff)
New upstream release.
Diffstat (limited to 'tests/convert-tests/012-reiserfs-large-hole-extent/test.sh')
-rwxr-xr-xtests/convert-tests/012-reiserfs-large-hole-extent/test.sh28
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/convert-tests/012-reiserfs-large-hole-extent/test.sh b/tests/convert-tests/012-reiserfs-large-hole-extent/test.sh
new file mode 100755
index 00000000..7a8d4972
--- /dev/null
+++ b/tests/convert-tests/012-reiserfs-large-hole-extent/test.sh
@@ -0,0 +1,28 @@
+#!/bin/bash
+# Create a base image with large hole extent, then convert to btrfs,
+# check the converted image.
+# Check if btrfs-convert can handle such large hole.
+# Fast pinpoint regression test. No options combination nor checksum
+# verification
+
+source "$TOP/tests/common"
+source "$TOP/tests/common.convert"
+
+if ! check_kernel_support_reiserfs >/dev/null; then
+ _not_run "no reiserfs support"
+fi
+
+setup_root_helper
+prepare_test_dev 512M
+check_prereq btrfs-convert
+check_global_prereq mkreiserfs
+
+default_mkfs="mkreiserfs -b 4096"
+convert_test_preamble '' 'large hole extent test' 16k "$default_mkfs"
+convert_test_prep_fs reiserfs $default_mkfs
+
+run_check $SUDO_HELPER dd if=/dev/zero of="$TEST_MNT/file" bs=1M \
+ count=1 seek=1024 > /dev/null 2>&1
+
+run_check_umount_test_dev
+convert_test_do_convert