Commit 5a339bbb by Stéphane Graber

api_test.py: Remove workarounds for API bugs

The script used to contain a workaround for back when create() wouldn't properly flush the config and reload it. As these issues have now been fixed, these workarounds can be removed. Signed-off-by: 's avatarStéphane Graber <stgraber@ubuntu.com>
parent abbe2ead
...@@ -53,7 +53,6 @@ assert(container.state == "STOPPED") ...@@ -53,7 +53,6 @@ assert(container.state == "STOPPED")
## Create a rootfs ## Create a rootfs
print("Creating rootfs using '%s'" % LXC_TEMPLATE) print("Creating rootfs using '%s'" % LXC_TEMPLATE)
container.create(LXC_TEMPLATE) container.create(LXC_TEMPLATE)
container.load_config() # FIXME: workaround for get_config_item segfault
assert(container.defined == True) assert(container.defined == True)
assert(container.name == CONTAINER_NAME assert(container.name == CONTAINER_NAME
...@@ -74,7 +73,6 @@ assert(capdrop == container.get_config_item("lxc.cap.drop")) ...@@ -74,7 +73,6 @@ assert(capdrop == container.get_config_item("lxc.cap.drop"))
## Test the networking ## Test the networking
print("Testing the networking") print("Testing the networking")
container.network.remove(0) # FIXME: workaround for get_config_item segfault
# A few basic checks of the current state # A few basic checks of the current state
assert("name" in container.get_keys("lxc.network.0")) assert("name" in container.get_keys("lxc.network.0"))
...@@ -142,8 +140,6 @@ assert(container.state == "STOPPED") ...@@ -142,8 +140,6 @@ assert(container.state == "STOPPED")
print("Cloning the container") print("Cloning the container")
clone = lxc.Container(CLONE_NAME) clone = lxc.Container(CLONE_NAME)
clone.clone(container) clone.clone(container)
clone.load_config() # FIXME: workaround for get_config_item segfault
clone.network.remove(0) # FIXME: workaround for get_config_item segfault
clone.start() clone.start()
clone.stop() clone.stop()
clone.destroy() clone.destroy()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment