path: root/tests
diff options
authorDavid Sterba <>2015-04-07 18:09:18 +0200
committerDavid Sterba <>2015-04-07 18:36:55 +0200
commit35d53302ac961d8d7706318f9d6d12282f712703 (patch)
tree96ac43efaa97adced8259926e2adf6a6f6af0766 /tests
parent96563f961c6a7fede89dc85cdeaec2158bbc66e8 (diff)
btrfs-progs: convert tests: preserve test image permissions
If the test image is eg. on NFS it's not writable for root, so chmod 0777 fixes that but then we must not delete the file. Signed-off-by: David Sterba <>
Diffstat (limited to 'tests')
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/ b/tests/
index 42cbeb60..7976f662 100644
--- a/tests/
+++ b/tests/
@@ -24,8 +24,10 @@ convert_test() {
shift 2
echo "creating ext image with: $*" >> $RESULTS
+ # IMAGE not removed as the file might have special permissions, eg.
+ # when test image is on NFS and would not be writable for root
+ run_check truncate -s 0 $IMAGE
# 256MB is the smallest acceptable btrfs image.
- run_check rm -f $IMAGE
run_check truncate -s 256M $IMAGE
run_check $* -F $IMAGE