annotate makeitso/python_package/tests/unit.py @ 150:59feed7c9b4a

convenience import
author Jeff Hammel <jhammel@mozilla.com>
date Sat, 24 Mar 2012 11:16:52 -0700
parents e3ba71e7b927
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
147
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
1 #!/usr/bin/env python
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
2
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
3 """
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
4 unit tests
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
5 """
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
6
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
7 import os
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
8 import sys
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
9 import unittest
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
10
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
11 # globals
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
12 here = os.path.dirname(os.path.abspath(__file__))
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
13
148
e3ba71e7b927 correct capitalization
Jeff Hammel <jhammel@mozilla.com>
parents: 147
diff changeset
14 class {{package}}UnitTest(unittest.TestCase):
147
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
15
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
16 def test_{{package}}(self):
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
17 pass
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
18
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
19 if __name__ == '__main__':
bdf4049e83ea add a unit test skeleton
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
20 unittest.main()