Home | History | Annotate | Download | only in test
      1 # Fictitious test runner for the project
      2 
      3 import sys, os
      4 
      5 if sys.version_info > (3,):
      6     # copy test suite over to "build/lib" and convert it
      7     from distutils.util import copydir_run_2to3
      8     testroot = os.path.dirname(__file__)
      9     newroot = os.path.join(testroot, '..', 'build/lib/test')
     10     copydir_run_2to3(testroot, newroot)
     11     # in the following imports, pick up the converted modules
     12     sys.path[0] = newroot
     13 
     14 # run the tests here...
     15 
     16 from test_foo import FooTest
     17 
     18 import unittest
     19 unittest.main()
     20