Fix test that checks whether insances from previous runs need to be removed

* Fixes bug 919389

Change-Id: I11e0c46426e627448562802e56fca186a5a365ef
This commit is contained in:
Anthony Young 2012-01-20 12:45:32 -08:00
parent 723d72d45e
commit edef244e40

View File

@ -930,7 +930,7 @@ if [[ "$ENABLED_SERVICES" =~ "n-cpu" ]]; then
# Destroy old instances
instances=`virsh list --all | grep $INSTANCE_NAME_PREFIX | sed "s/.*\($INSTANCE_NAME_PREFIX[0-9a-fA-F]*\).*/\1/g"`
if [ ! $instances = "" ]; then
if [ ! "$instances" = "" ]; then
echo $instances | xargs -n1 virsh destroy || true
echo $instances | xargs -n1 virsh undefine || true
fi