btrfs-progs: convert-test: Check if the ext2_save/image is read only
authorQu Wenruo <quwenruo@cn.fujitsu.com>
Fri, 19 Aug 2016 08:13:06 +0000 (16:13 +0800)
committerDavid Sterba <dsterba@suse.com>
Fri, 19 Aug 2016 11:53:28 +0000 (13:53 +0200)
commit4f3ccdd518cbea2a34f5a62099bb1ca2881fae9c
tree826f40fdc7922619f2c1ad9af7dbb01511a1c797
parentbdadea75e47f21682b745678c9b685e491c5e8a3
btrfs-progs: convert-test: Check if the ext2_save/image is read only

Old convert codes uses both 0400 permission and INODE_READONLY flag to
make the converted ext2 image readonly.

While new convert treat the inode just as normal inode, with no special
inode flag and uses 0600 permission.
This makes user able to modify converted image unintentionally and make
rollback fails.

This test case will test the regression.

Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
tests/convert-tests/008-readonly-image/test.sh [new file with mode: 0755]