Updated for 2.1a3
[python/dscho.git] / Lib / test / test_capi.py
blob9eddc88ff9d2d92f81e1f165dd81d64e52cd1ebe
1 # Run the _testcapi module tests (tests for the Python/C API): by defn,
2 # these are all functions _test exports whose name begins with 'test_'.
4 import sys
5 import test_support
6 import _testcapi
8 for name in dir(_testcapi):
9 if name.startswith('test_'):
10 test = getattr(_testcapi, name)
11 if test_support.verbose:
12 print "internal", name
13 try:
14 test()
15 except _testcapi.error:
16 raise test_support.TestFailed, sys.exc_info()[1]