]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
tests: remove lxc-test-ubuntu
authorChristian Brauner <christian.brauner@ubuntu.com>
Fri, 16 Feb 2018 14:56:24 +0000 (15:56 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Sat, 17 Feb 2018 12:49:30 +0000 (13:49 +0100)
This is really taking a long time for not a lot of benefit.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/tests/Makefile.am
src/tests/lxc-test-ubuntu [deleted file]

index e2e73c941f30f37cff3573a559b571af68d5658b..ea2cf8c763848a07b5814805c1ffc27ffbc62128 100644 (file)
@@ -73,7 +73,6 @@ bin_SCRIPTS += \
        lxc-test-checkpoint-restore \
        lxc-test-snapdeps \
        lxc-test-symlink \
-       lxc-test-ubuntu \
        lxc-test-unpriv \
        lxc-test-usernic
 endif
@@ -106,7 +105,6 @@ EXTRA_DIST = \
        lxc-test-createconfig \
        lxc-test-snapdeps \
        lxc-test-symlink \
-       lxc-test-ubuntu \
        lxc-test-unpriv \
        lxc-test-utils.c \
        may_control.c \
diff --git a/src/tests/lxc-test-ubuntu b/src/tests/lxc-test-ubuntu
deleted file mode 100755 (executable)
index a5e6204..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-#!/bin/sh
-
-# lxc-test-ubuntu: some tests of ubuntu-specific features of lxc.
-# Some features of lxc - networking and LSM configuration for instance -
-# are generally configured by the distro packages.  This program
-# tests the Ubuntu configuration.
-
-# These require the ubuntu lxc package to be installed.
-
-# General lxc functionality testing does not belong here.
-
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
-
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-
-set -e
-
-FAIL() {
-       echo -n "Failed " >&2
-       echo "$*" >&2
-       exit 1
-}
-
-# Only run on a normally configured ubuntu lxc system
-if [ ! -d /sys/class/net/lxcbr0 ]; then
-       echo "lxcbr0 is not configured."
-       exit 1
-fi
-if [ "$(id -u)" != "0" ]; then
-       echo "ERROR: Must run as root."
-       exit 1
-fi
-
-for template in ubuntu ubuntu-cloud; do
-       # need a different name for each container so dnsmasq doesn't
-       # mess us up with its caching
-       if which uuidgen 2>&1 > /dev/null; then
-               name=$(uuidgen)
-       else
-               name=lxc-test-$template
-       fi
-
-       lxc-create -t $template -n $name || FAIL "creating $template container"
-       lxc-start -n $name -d || FAIL "starting $template container"
-       lxc-wait -n $name -s RUNNING || FAIL "waiting for $template container to run"
-
-       for tries in `seq 1 20`; do
-               lxcip=$(lxc-info -i -n $name -H | head -n 1)
-               [ -z "$lxcip" ] || break
-               sleep 1
-       done
-       [ -n "$lxcip" ] || FAIL "to start networking in $template container"
-
-       if echo "${lxcip}" | grep -q ":"; then
-               ping6 -c 1 $lxcip || FAIL "to ping $template container"
-       else
-               ping -c 1 $lxcip || FAIL "to ping $template container"
-       fi
-
-       # Check apparmor
-       lxcpid=`lxc-info -n $name -p -H`
-       aa=`cat /proc/$lxcpid/attr/current`
-       if [ "$aa" != "lxc-container-default-with-nesting (enforce)" -a \
-                       "$aa" != "lxc-container-default-cgns (enforce)" -a \
-                       "$aa" != "lxc-container-default (enforce)" ]; then
-               FAIL " to correctly set apparmor profile (profile is \"$aa\")"
-       fi
-       lxc-stop -n $name -k
-       lxc-destroy -n $name
-done
-
-exit 0