[1/2] btrfs-progs: mkfs-tests: Set $csum so mkfs.btrfs does not fail
diff mbox series

Message ID 20191205153647.31961-1-marcos.souza.org@gmail.com
State New
Headers show
Series
  • [1/2] btrfs-progs: mkfs-tests: Set $csum so mkfs.btrfs does not fail
Related show

Commit Message

Marcos Paulo de Souza Dec. 5, 2019, 3:36 p.m. UTC
From: Marcos Paulo de Souza <mpdesouza@suse.com>

Signed-off-by: Marcos Paulo de Souza <mpdesouza@suse.com>
---
 tests/mkfs-tests/020-basic-checksums-mount/test.sh | 1 +
 1 file changed, 1 insertion(+)

Comments

Nikolay Borisov Dec. 10, 2019, 8:33 a.m. UTC | #1
On 5.12.19 г. 17:36 ч., Marcos Paulo de Souza wrote:
> From: Marcos Paulo de Souza <mpdesouza@suse.com>
> 
> Signed-off-by: Marcos Paulo de Souza <mpdesouza@suse.com>

Reviewed-by: Nikolay Borisov <nborisov@suse.com>

> ---
>  tests/mkfs-tests/020-basic-checksums-mount/test.sh | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tests/mkfs-tests/020-basic-checksums-mount/test.sh b/tests/mkfs-tests/020-basic-checksums-mount/test.sh
> index 41ef5417..b7252786 100755
> --- a/tests/mkfs-tests/020-basic-checksums-mount/test.sh
> +++ b/tests/mkfs-tests/020-basic-checksums-mount/test.sh
> @@ -12,6 +12,7 @@ prepare_test_dev
>  
>  test_mkfs_mount_checksum()
>  {
> +	csum=$1
>  	run_check_stdout $SUDO_HELPER "$TOP/mkfs.btrfs" -f --csum "$csum" "$TEST_DEV" | grep -q "Checksum:.*$csum"
>  	run_check $SUDO_HELPER "$TOP/btrfs" inspect-internal dump-super "$TEST_DEV"
>  	run_check $SUDO_HELPER "$TOP/btrfs" check "$TEST_DEV"
>

Patch
diff mbox series

diff --git a/tests/mkfs-tests/020-basic-checksums-mount/test.sh b/tests/mkfs-tests/020-basic-checksums-mount/test.sh
index 41ef5417..b7252786 100755
--- a/tests/mkfs-tests/020-basic-checksums-mount/test.sh
+++ b/tests/mkfs-tests/020-basic-checksums-mount/test.sh
@@ -12,6 +12,7 @@  prepare_test_dev
 
 test_mkfs_mount_checksum()
 {
+	csum=$1
 	run_check_stdout $SUDO_HELPER "$TOP/mkfs.btrfs" -f --csum "$csum" "$TEST_DEV" | grep -q "Checksum:.*$csum"
 	run_check $SUDO_HELPER "$TOP/btrfs" inspect-internal dump-super "$TEST_DEV"
 	run_check $SUDO_HELPER "$TOP/btrfs" check "$TEST_DEV"