diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2012-03-16 13:00:05 +0000 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2012-03-16 13:00:05 +0000 |
commit | 351be15dc481a130ca880121b53f849e1053c687 (patch) | |
tree | 953399bafee31d9bc34e82166efefcfb44e1e7f1 /test/shell/vgchange-sysinit.sh | |
parent | cce2475889ae32e8bfff6d35dc797e6054372120 (diff) | |
download | lvm2-351be15dc481a130ca880121b53f849e1053c687.tar.gz lvm2-351be15dc481a130ca880121b53f849e1053c687.tar.xz lvm2-351be15dc481a130ca880121b53f849e1053c687.zip |
Update tests
Indent
Shell improvements - use internal function for checks
Use PVs in "" (LV and VG cannot have spaces)
Several test very starting 'dmeventd' without annoucing
it via prepade_dmeventd.
Fix some of test actually.
Diffstat (limited to 'test/shell/vgchange-sysinit.sh')
-rw-r--r-- | test/shell/vgchange-sysinit.sh | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/shell/vgchange-sysinit.sh b/test/shell/vgchange-sysinit.sh index a9f24780..d7a166c9 100644 --- a/test/shell/vgchange-sysinit.sh +++ b/test/shell/vgchange-sysinit.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh # Copyright (C) 2011 Red Hat, Inc. All rights reserved. # # This copyrighted material is made available to anyone wishing to use, @@ -11,32 +11,32 @@ . lib/test -which mkfs.ext3 || exit 200 +which mkfs.ext3 || skip aux prepare_pvs 2 8 -test -e LOCAL_CLVMD && exit 200 +test -e LOCAL_CLVMD && skip var_lock="$DM_DEV_DIR/$vg1/$lv1" # keep in sync with aux configured lockingdir -mount_dir="$TESTDIR/var/lock/lvm" +mount_dir="var/lock/lvm" cleanup_mounted_and_teardown() { - umount $mount_dir || true + umount "$mount_dir" || true aux teardown } -vgcreate -c n $vg1 $dev1 -vgcreate -c n $vg2 $dev2 +vgcreate -c n $vg1 "$dev1" +vgcreate -c n $vg2 "$dev2" lvcreate -l 1 -n $lv2 $vg2 vgchange -an $vg2 lvcreate -n $lv1 -l 100%FREE $vg1 -mkfs.ext3 -b4096 -j $var_lock +mkfs.ext3 -b4096 -j "$var_lock" trap 'cleanup_mounted_and_teardown' EXIT -mount -n -r $var_lock $mount_dir +mount -n -r "$var_lock" "$mount_dir" # locking must fail on read-only filesystem not vgchange -ay $vg2 |