Mercurial > hg > Lemuriformes
annotate tests/test_waiter.py @ 18:56596902e9ae default tip
add some setup + tests
author | Jeff Hammel <k0scist@gmail.com> |
---|---|
date | Sun, 10 Dec 2017 17:57:03 -0800 |
parents | |
children |
rev | line source |
---|---|
18 | 1 #!/usr/bin/env python |
2 | |
3 """ | |
4 test bash waiting function | |
5 """ | |
6 | |
7 import os | |
8 import shutil | |
9 import tempfile | |
10 import unittest | |
11 from lemuriformes import waiter | |
12 | |
13 string = (str, unicode) | |
14 | |
15 | |
16 class TestWaiter(unittest.TestCase): | |
17 | |
18 def test_render(self): | |
19 commands = ['echo {}'.format(item) | |
20 for item in ('hello', 'world')] | |
21 hello = str(waiter.BashWaiter(*commands)) | |
22 assert isinstance(hello, string) | |
23 | |
24 | |
25 if __name__ == '__main__': | |
26 unittest.main() |