comparison makeitso/python_package/tests/test.py @ 146:ebaee69c5ea4

whitespace
author Jeff Hammel <jhammel@mozilla.com>
date Mon, 05 Mar 2012 14:32:21 -0800
parents c07dd14d5842
children
comparison
equal deleted inserted replaced
145:c07dd14d5842 146:ebaee69c5ea4
22 doctest_args['optionsflags'] = doctest.ELLIPSIS 22 doctest_args['optionsflags'] = doctest.ELLIPSIS
23 if report_first: 23 if report_first:
24 doctest_args['optionflags'] |= doctest.REPORT_ONLY_FIRST_FAILURE 24 doctest_args['optionflags'] |= doctest.REPORT_ONLY_FIRST_FAILURE
25 25
26 # gather tests 26 # gather tests
27 tests = [ test for test in os.listdir(directory) 27 tests = [test for test in os.listdir(directory)
28 if test.endswith('.txt') ] 28 if test.endswith('.txt')]
29 29
30 # run the tests 30 # run the tests
31 for test in tests: 31 for test in tests:
32 try: 32 try:
33 results[test] = doctest.testfile(test, **doctest_args) 33 results[test] = doctest.testfile(test, **doctest_args)