mirror of
https://github.com/kdave/btrfs-progs
synced 2024-12-27 00:22:22 +00:00
9d98ad1db5
Create a ready-to-use templates for the most common tests, copied from readme. Signed-off-by: David Sterba <dsterba@suse.com>
17 lines
409 B
Bash
17 lines
409 B
Bash
#!/bin/bash
|
|
# Create a new multi-device filesystem and test that it can be mounted
|
|
|
|
source "$TEST_TOP/common"
|
|
|
|
setup_root_helper
|
|
setup_loopdevs 4
|
|
prepare_loopdevs
|
|
TEST_DEV=${loopdevs[1]}
|
|
|
|
run_check $SUDO_HELPER "$TOP/mkfs.btrfs" -f -d raid1 -m raid1 "${loopdevs[@]}"
|
|
run_check_mount_test_dev
|
|
run_check $SUDO_HELPER dd if=/dev/zero of="$TEST_MNT"/file bs=1M count=1
|
|
run_check_umount_test_dev
|
|
|
|
cleanup_loopdevs
|