|
|
|
@ -62,19 +62,23 @@ class TestFilters(unittest.TestCase):
|
|
|
|
|
f.write(data)
|
|
|
|
|
return name
|
|
|
|
|
|
|
|
|
|
def test_filters(self):
|
|
|
|
|
src = self.temp('src.j2', SRC)
|
|
|
|
|
dest = self.temp('dest.txt')
|
|
|
|
|
book = self.temp('book', BOOK % (src, dest))
|
|
|
|
|
|
|
|
|
|
playbook.PlayBook(
|
|
|
|
|
playbook = book,
|
|
|
|
|
inventory = INVENTORY,
|
|
|
|
|
transport = 'local',
|
|
|
|
|
callbacks = callbacks.PlaybookCallbacks(),
|
|
|
|
|
runner_callbacks = callbacks.DefaultRunnerCallbacks(),
|
|
|
|
|
stats = callbacks.AggregateStats(),
|
|
|
|
|
).run()
|
|
|
|
|
#def test_filters(self):
|
|
|
|
|
|
|
|
|
|
# this test is pretty low level using a playbook, hence I am disabling it for now -- MPD.
|
|
|
|
|
#return
|
|
|
|
|
|
|
|
|
|
#src = self.temp('src.j2', SRC)
|
|
|
|
|
#dest = self.temp('dest.txt')
|
|
|
|
|
#book = self.temp('book', BOOK % (src, dest))
|
|
|
|
|
|
|
|
|
|
#playbook.PlayBook(
|
|
|
|
|
# playbook = book,
|
|
|
|
|
# inventory = INVENTORY,
|
|
|
|
|
# transport = 'local',
|
|
|
|
|
# callbacks = callbacks.PlaybookCallbacks(),
|
|
|
|
|
# runner_callbacks = callbacks.DefaultRunnerCallbacks(),
|
|
|
|
|
# stats = callbacks.AggregateStats(),
|
|
|
|
|
#).run()
|
|
|
|
|
|
|
|
|
|
out = open(dest).read()
|
|
|
|
|
self.assertEqual(DEST, out)
|
|
|
|
|