Add rm_alias test

This commit is contained in:
Thomas S Hatch 2012-05-14 10:44:17 -06:00
parent fcfc4c470c
commit 8e26ea646e

View File

@ -54,3 +54,21 @@ class AliasesTest(integration.ModuleCase):
'aliases.list_aliases')
self.assertIsInstance(tgt_ret, dict)
self.assertIn('alias=fred', tgt_ret)
def test_rm_alias(self):
'''
aliases.rm_alias
'''
set_ret = self.run_function(
'aliases.set_target',
alias='frank',
target='greg')
self.assertTrue(set_ret)
set_ret = self.run_function(
'aliases.rm_alias',
alias='frank')
tgt_ret = self.run_function(
'aliases.list_aliases')
self.assertIsInstance(tgt_ret, dict)
self.assertNotIn('alias=frank', tgt_ret)