test_ctypes.py 411 Bytes
Newer Older
1
import unittest
2

3 4 5 6 7
from test.support import run_unittest, import_module

# Skip tests if _ctypes module was not built.
import_module('_ctypes')

8 9 10 11 12
import ctypes.test

def test_main():
    skipped, testcases = ctypes.test.get_tests(ctypes.test, "test_*.py", verbosity=0)
    suites = [unittest.makeSuite(t) for t in testcases]
13
    run_unittest(unittest.TestSuite(suites))
14 15 16

if __name__ == "__main__":
    test_main()