mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Add initial aliases tests
This commit is contained in:
parent
c5df9f6526
commit
b97ec99999
27
tests/integration/modules/aliases.py
Normal file
27
tests/integration/modules/aliases.py
Normal file
@ -0,0 +1,27 @@
|
||||
# Import python libs
|
||||
import os
|
||||
import sys
|
||||
import hashlib
|
||||
|
||||
# Import salt libs
|
||||
from saltunittest import TestLoader, TextTestRunner
|
||||
import integration
|
||||
from integration import TestDaemon
|
||||
|
||||
class AliasesTest(integration.ModuleCase):
|
||||
'''
|
||||
Validate aliases module
|
||||
'''
|
||||
def test_set_target(self):
|
||||
'''
|
||||
aliases.set_target and aliases.get_target
|
||||
'''
|
||||
set_ret = self.run_function(
|
||||
'aliases.set_target',
|
||||
alias='fred',
|
||||
target='bob')
|
||||
self.assertTrue(set_ret)
|
||||
tgt_ret = self.run_function(
|
||||
'aliases.get_target',
|
||||
alias='fred')
|
||||
self.assertEqual(tgt_ret, 'target=bob')
|
Loading…
Reference in New Issue
Block a user