comparison tests/unit.py @ 19:cadc9514f60a

we have a legitimately failing test!
author Jeff Hammel <jhammel@mozilla.com>
date Mon, 26 Mar 2012 13:54:43 -0700
parents e00afe2c83bf
children 39f2611db9be
comparison
equal deleted inserted replaced
18:d8871956536e 19:cadc9514f60a
6 6
7 import os 7 import os
8 import sys 8 import sys
9 import unittest 9 import unittest
10 10
11 import example # example configuration to test 11 from example import ExampleConfiguration # example configuration to test
12 12
13 # globals 13 # globals
14 here = os.path.dirname(os.path.abspath(__file__)) 14 here = os.path.dirname(os.path.abspath(__file__))
15 15
16 class configurationUnitTest(unittest.TestCase): 16 class configurationUnitTest(unittest.TestCase):
17 17
18 def test_configuration(self): 18 def test_configuration(self):
19 19 example = ExampleConfiguration()
20
21 # parse command line arguments
22 options, args = example.parse(['-a', 'ts', '--develop', '-e', '/home/jhammel/bin/firefox'])
23 self.assertEqual(bool(args), False) # no arguments
24 self.assertEqual(options.develop, True)
20 25
21 if __name__ == '__main__': 26 if __name__ == '__main__':
22 unittest.main() 27 unittest.main()
23 28