api_test.py revision 03bd7f728ed8605210c93fec739c612972484e8c
# (C) Copyright Canonical Ltd. 2012 # Stéphane Graber <stgraber@ubuntu.com> # This library 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 # Let's pick a random name, avoiding clashes ## Instantiate the container instance # A few basic checks of the current state # Try to get the host architecture for dpkg systems print(
"Creating rootfs using 'download', arch=%s" %
arch)
print(
"Testing the configuration")
# A few basic checks of the current state print(
"Testing the networking")
# A few basic checks of the current state ## Starting the container print(
"Starting the container")
# A few basic checks of the current state print(
"Getting the interface names")
print(
"Getting the IP addresses")
# A few basic checks of the current state print(
"Testing cgroup API")
## Freezing the container print(
"Freezing the container")
# A few basic checks of the current state ## Unfreezing the container print(
"Unfreezing the container")
# A few basic checks of the current state print(
"Attaching to tty1")
## Shutting down the container print(
"Shutting down the container")
print(
"Stopping the container")
# A few basic checks of the current state ## Snapshotting the container print(
"Snapshotting the container")
print(
"Cloning the container as '%s'" %
CLONE_NAME)
print(
"Destroying the container")