Mercurial > hg > MakeItSo
view makeitso/python_package/tests/test_{{package}}.py @ 205:0a991b8fe839
better check
author | Jeff Hammel <k0scist@gmail.com> |
---|---|
date | Fri, 21 Nov 2014 12:19:07 -0800 |
parents | 84be91d59996 |
children | f7f7831f7c8c |
line wrap: on
line source
#!/usr/bin/env python """ unit tests """ import os import sys import tempfile import unittest # globals here = os.path.dirname(os.path.abspath(__file__)) class {{package}}UnitTest(unittest.TestCase): def test_{{package}}(self): tf = tempfile.mktemp() try: # pass pass finally: if os.path.exists(tf): os.remove(tf) if __name__ == '__main__': unittest.main()