00001 # -*- coding: ascii -*- 00002 00003 import unittest, os, os.path, sys 00004 from doctest import DocTestSuite 00005 00006 # We test the documentation this way instead of using DocFileSuite so 00007 # we can run the tests under Python 2.3 00008 def test_README(): 00009 pass 00010 00011 this_dir = os.path.dirname(__file__) 00012 locs = [ 00013 os.path.join(this_dir, os.pardir, 'README.txt'), 00014 os.path.join(this_dir, os.pardir, os.pardir, 'README.txt'), 00015 ] 00016 for loc in locs: 00017 if os.path.exists(loc): 00018 test_README.__doc__ = open(loc).read() 00019 break 00020 if test_README.__doc__ is None: 00021 raise RuntimeError('README.txt not found') 00022 00023 00024 def test_suite(): 00025 "For the Z3 test runner" 00026 return DocTestSuite() 00027 00028 00029 if __name__ == '__main__': 00030 sys.path.insert(0, os.path.abspath(os.path.join( 00031 this_dir, os.pardir, os.pardir 00032 ))) 00033 unittest.main(defaultTest='test_suite') 00034 00035 00036 00037
© Copyright 2008-2009 Vyper Logix Corp., All Right Reserved; If you reference this document or any part of this document you must use the citation verbatim (including the link) "© Copyright 2008-2009 Vyper Logix Corp., All Right Reserved."
Notice: This source code contained in this document is NOT open source and is NOT being distributed as open source.
122,241 lines of code and growing...