summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2015-10-27 00:45:37 +0100
committerZdenek Kabelac <zkabelac@redhat.com>2015-10-27 00:45:37 +0100
commit3b5939bbbb974913db3ff7ac363cc7f1154b894e (patch)
treefe6751205a609a6b64caaf46ad29cae475d871d0
parenta2dd1f6e191de8d0ba1292e01338d480958c5a0a (diff)
downloadlvm2-3b5939bbbb974913db3ff7ac363cc7f1154b894e.tar.gz
tests: use skip flags
corrected usage of skip flags.
-rw-r--r--test/shell/activate-minor.sh3
-rw-r--r--test/shell/activate-missing-segment.sh4
-rw-r--r--test/shell/activate-missing.sh4
-rw-r--r--test/shell/activate-partial.sh4
-rw-r--r--test/shell/activation-skip.sh4
-rw-r--r--test/shell/clvmd-restart.sh5
-rw-r--r--test/shell/lvmetad-ambiguous.sh6
-rw-r--r--test/shell/lvmetad-autoshutdown.sh6
-rw-r--r--test/shell/lvmetad-client-filter.sh6
-rw-r--r--test/shell/lvmetad-disabled.sh6
-rw-r--r--test/shell/lvmetad-dump.sh6
-rw-r--r--test/shell/lvmetad-lvm1.sh6
-rw-r--r--test/shell/lvmetad-lvscan-cache.sh6
-rw-r--r--test/shell/lvmetad-no-cluster.sh3
-rw-r--r--test/shell/lvmetad-override.sh6
-rw-r--r--test/shell/lvmetad-pvs.sh4
-rw-r--r--test/shell/lvmetad-pvscan-cache.sh6
-rw-r--r--test/shell/lvmetad-pvscan-filter.sh6
-rw-r--r--test/shell/lvmetad-pvscan-md.sh6
-rw-r--r--test/shell/lvmetad-pvscan-nomda-bg.sh6
-rw-r--r--test/shell/lvmetad-pvscan-nomda.sh6
-rw-r--r--test/shell/lvmetad-restart.sh6
-rw-r--r--test/shell/lvmetad-test.sh4
-rw-r--r--test/shell/lvmetad-warning.sh6
24 files changed, 65 insertions, 60 deletions
diff --git a/test/shell/activate-minor.sh b/test/shell/activate-minor.sh
index d7ae5f90d..086a1cafa 100644
--- a/test/shell/activate-minor.sh
+++ b/test/shell/activate-minor.sh
@@ -9,12 +9,13 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+SKIP_WITH_LVMPOLLD=1
+
. lib/inittest
# Just skip this test if minor is already in use...
dmsetup info | tee info
egrep "^Major, minor: *[0-9]+, 123" info && skip
-test -e LOCAL_LVMPOLLD && skip
aux prepare_vg 2
lvcreate -a n --zero n -l 1 -n foo $vg
diff --git a/test/shell/activate-missing-segment.sh b/test/shell/activate-missing-segment.sh
index 988c9cbb8..05d6a366a 100644
--- a/test/shell/activate-missing-segment.sh
+++ b/test/shell/activate-missing-segment.sh
@@ -16,9 +16,9 @@
# instead lvconvert --repair them?)
# - linear LVs with bits missing are not activated
-. lib/inittest
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_vg 2
diff --git a/test/shell/activate-missing.sh b/test/shell/activate-missing.sh
index e33a6ef6c..3078b9ddc 100644
--- a/test/shell/activate-missing.sh
+++ b/test/shell/activate-missing.sh
@@ -16,9 +16,9 @@
# instead lvconvert --repair them?)
# - linear LVs with bits missing are not activated
-. lib/inittest
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_vg 4
diff --git a/test/shell/activate-partial.sh b/test/shell/activate-partial.sh
index 3720e1d26..75a66e230 100644
--- a/test/shell/activate-partial.sh
+++ b/test/shell/activate-partial.sh
@@ -9,9 +9,9 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_vg 3
diff --git a/test/shell/activation-skip.sh b/test/shell/activation-skip.sh
index 5259d9dfd..18bb2185c 100644
--- a/test/shell/activation-skip.sh
+++ b/test/shell/activation-skip.sh
@@ -9,9 +9,9 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
# Test skip activation flag -k|--setactivationskip
diff --git a/test/shell/clvmd-restart.sh b/test/shell/clvmd-restart.sh
index afe48346c..5d8525f60 100644
--- a/test/shell/clvmd-restart.sh
+++ b/test/shell/clvmd-restart.sh
@@ -13,11 +13,12 @@
export LVM_CLVMD_BINARY=clvmd
export LVM_BINARY=lvm
+SKIP_WITHOUT_CLVMD=1
+SKIP_WITH_LVMPOLLD=1
+
. lib/inittest
# only clvmd based test, skip otherwise
-test -e LOCAL_LVMPOLLD && skip
-test -e LOCAL_CLVMD || skip
read LOCAL_CLVMD < LOCAL_CLVMD
# TODO read from build, for now hardcoded
diff --git a/test/shell/lvmetad-ambiguous.sh b/test/shell/lvmetad-ambiguous.sh
index 777a63e83..1711f717c 100644
--- a/test/shell/lvmetad-ambiguous.sh
+++ b/test/shell/lvmetad-ambiguous.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-autoshutdown.sh b/test/shell/lvmetad-autoshutdown.sh
index fdee4a6f8..425ee336c 100644
--- a/test/shell/lvmetad-autoshutdown.sh
+++ b/test/shell/lvmetad-autoshutdown.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
kill -0 $(< LOCAL_LVMETAD) || die "lvmetad is already dead"
diff --git a/test/shell/lvmetad-client-filter.sh b/test/shell/lvmetad-client-filter.sh
index 5e6d967cf..4119e641e 100644
--- a/test/shell/lvmetad-client-filter.sh
+++ b/test/shell/lvmetad-client-filter.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-disabled.sh b/test/shell/lvmetad-disabled.sh
index 9c71717a3..4f1516552 100644
--- a/test/shell/lvmetad-disabled.sh
+++ b/test/shell/lvmetad-disabled.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
kill $(< LOCAL_LVMETAD)
while test -e "$TESTDIR/lvmetad.socket"; do echo -n .; sleep .1; done # wait for the socket close
diff --git a/test/shell/lvmetad-dump.sh b/test/shell/lvmetad-dump.sh
index 631636ea6..c9a7736bd 100644
--- a/test/shell/lvmetad-dump.sh
+++ b/test/shell/lvmetad-dump.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
vgcreate $vg1 "$dev1" "$dev2"
diff --git a/test/shell/lvmetad-lvm1.sh b/test/shell/lvmetad-lvm1.sh
index f234b154c..3b14fdd89 100644
--- a/test/shell/lvmetad-lvm1.sh
+++ b/test/shell/lvmetad-lvm1.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_devs 2
pvcreate --metadatatype 1 "$dev1"
diff --git a/test/shell/lvmetad-lvscan-cache.sh b/test/shell/lvmetad-lvscan-cache.sh
index 220e464c7..a4a098237 100644
--- a/test/shell/lvmetad-lvscan-cache.sh
+++ b/test/shell/lvmetad-lvscan-cache.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-no-cluster.sh b/test/shell/lvmetad-no-cluster.sh
index 83fee47fd..0421c59b4 100644
--- a/test/shell/lvmetad-no-cluster.sh
+++ b/test/shell/lvmetad-no-cluster.sh
@@ -9,6 +9,9 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+SKIP_WITHOUT_CLVMD=1
+SKIP_WITH_LVMPOLLD=1
+
. lib/inittest
test -e LOCAL_CLVMD || skip
diff --git a/test/shell/lvmetad-override.sh b/test/shell/lvmetad-override.sh
index 15ada7b01..a0a983b1b 100644
--- a/test/shell/lvmetad-override.sh
+++ b/test/shell/lvmetad-override.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-pvs.sh b/test/shell/lvmetad-pvs.sh
index 81174f4cd..3014a67d6 100644
--- a/test/shell/lvmetad-pvs.sh
+++ b/test/shell/lvmetad-pvs.sh
@@ -9,9 +9,9 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMPOLLD=1
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 1 20000
pvs $(cat DEVICES) | grep "$dev1"
diff --git a/test/shell/lvmetad-pvscan-cache.sh b/test/shell/lvmetad-pvscan-cache.sh
index 33b4d942c..f2a3afa0e 100644
--- a/test/shell/lvmetad-pvscan-cache.sh
+++ b/test/shell/lvmetad-pvscan-cache.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-pvscan-filter.sh b/test/shell/lvmetad-pvscan-filter.sh
index b7bdf339b..8ec31edf8 100644
--- a/test/shell/lvmetad-pvscan-filter.sh
+++ b/test/shell/lvmetad-pvscan-filter.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-pvscan-md.sh b/test/shell/lvmetad-pvscan-md.sh
index 9c5e3fa58..82831e54e 100644
--- a/test/shell/lvmetad-pvscan-md.sh
+++ b/test/shell/lvmetad-pvscan-md.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
test -f /proc/mdstat && grep -q raid0 /proc/mdstat || \
modprobe raid0 || skip
diff --git a/test/shell/lvmetad-pvscan-nomda-bg.sh b/test/shell/lvmetad-pvscan-nomda-bg.sh
index e17dfd27b..5cf460224 100644
--- a/test/shell/lvmetad-pvscan-nomda-bg.sh
+++ b/test/shell/lvmetad-pvscan-nomda-bg.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
kill $(< LOCAL_LVMETAD)
rm LOCAL_LVMETAD
diff --git a/test/shell/lvmetad-pvscan-nomda.sh b/test/shell/lvmetad-pvscan-nomda.sh
index f7e13a72b..6a78b6cf3 100644
--- a/test/shell/lvmetad-pvscan-nomda.sh
+++ b/test/shell/lvmetad-pvscan-nomda.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
kill $(< LOCAL_LVMETAD)
rm LOCAL_LVMETAD
diff --git a/test/shell/lvmetad-restart.sh b/test/shell/lvmetad-restart.sh
index 8805bc8b8..18b2b2c14 100644
--- a/test/shell/lvmetad-restart.sh
+++ b/test/shell/lvmetad-restart.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-test.sh b/test/shell/lvmetad-test.sh
index 146a7f19e..7d4797996 100644
--- a/test/shell/lvmetad-test.sh
+++ b/test/shell/lvmetad-test.sh
@@ -9,9 +9,9 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2
diff --git a/test/shell/lvmetad-warning.sh b/test/shell/lvmetad-warning.sh
index 44edb125a..4c8cc5951 100644
--- a/test/shell/lvmetad-warning.sh
+++ b/test/shell/lvmetad-warning.sh
@@ -9,10 +9,10 @@
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-. lib/inittest
+SKIP_WITHOUT_LVMETAD=1
+SKIP_WITH_LVMPOLLD=1
-test -e LOCAL_LVMETAD || skip
-test -e LOCAL_LVMPOLLD && skip
+. lib/inittest
aux prepare_pvs 2