Disable LXC integration tests for now

This commit is contained in:
Erik Johnson 2015-01-29 17:40:42 -06:00
parent a90759584a
commit 706ce858b4

View File

@ -5,20 +5,27 @@ Test the lxc module
'''
# Import Salt Testing libs
from salttesting.helpers import ensure_in_syspath, skip_if_not_root, skip_if_binaries_missing
from salttesting.helpers import (
ensure_in_syspath,
skip_if_not_root,
skip_if_binaries_missing
)
from salttesting import skipIf
ensure_in_syspath('../../')
# Import salt libs
import integration
@skipIf(True,
'Needs rewrite to be more distro agnostic. Also, the tearDown '
'function destroys ALL containers on the box, which is BAD.')
@skip_if_not_root
@skip_if_binaries_missing('lxc-start', message='LXC is not installed or minimal version not met')
class LXCModuleTest(integration.ModuleCase):
'''
Test the lxc module
'''
prefix = '_salttesting'
def setUp(self):
@ -50,7 +57,8 @@ class LXCModuleTest(integration.ModuleCase):
r = self.run_function('lxc.create', [self.prefix],
template='sshd')
self.assertEqual(r, {'created': True})
self.assertEqual(r, {'state': {'new': 'stopped', 'old': None},
'result': True})
self.assertTrue(self.run_function('lxc.exists', [self.prefix]))
r = self.run_function('lxc.destroy', [self.prefix])
self.assertEqual(r, {'state': None, 'change': True})