On Fri, Jul 05, 2019 at 03:26:51PM +0800, Qu Wenruo wrote:
> Most convert tests needs to mount the converted image, and both reiserfs
> and ext* uses 4k block size, on 32K page size system we can't mount them
> and will cause test failure.
> 
> Skip most of convert tests, except 007-unsupported-block-sizes, which
> should fail on all systems.

Ok agreed, I don't see a better way than to skip the tests. Some of them
can be made to work based on the page size and adjusting the
ext4/reiserfs block sizes.

As this requires hw support to verify that test works, I would rather do
that one by one at the expense that non-4k page testing coverage will be
missing.

I saw some tests were using the assumptions of 4k sectorsize for some
test file generation so to avoid silent breakage, reviewing change to
each test should give some guarantees.

Alternatively, tests can be extended to iterate over the block sizes
from 4k to 64k. But then it's again difficult to see which combinations
make sense and must succeed or not. Oh well.

> --- a/tests/convert-tests/006-large-hole-extent/test.sh
> +++ b/tests/convert-tests/006-large-hole-extent/test.sh
> @@ -11,6 +11,8 @@ source "$TEST_TOP/common.convert"
>  setup_root_helper
>  prepare_test_dev
>  check_prereq btrfs-convert
> +check_prereq_mount_with_sectorsize 4096
> +prepare_test_dev

See, this is an example why the pre-checks should be independent,
requiring to call prepare_test_dev again is quite counter-intuitive and
error prone.

>  check_global_prereq mke2fs
>  
>  default_mke2fs="mke2fs -t ext4 -b 4096"

Reply via email to