summaryrefslogtreecommitdiff
path: root/Lib/test/test_cl.py
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2008-03-03 04:19:29 +0000
committerBrett Cannon <bcannon@gmail.com>2008-03-03 04:19:29 +0000
commita61d58722ddb976ba8c413338995ad515dd6988f (patch)
treec0d2700c010f550db94f51f218cf557dfdae1af3 /Lib/test/test_cl.py
parent3a13d49e989add10ac87c297cb59053d0b4ca8a5 (diff)
downloadcpython-a61d58722ddb976ba8c413338995ad515dd6988f.tar.gz
Add test_main() functions to various tests where it was simple to do. Done so
that regrtest can execute the test_main() directly instead of relying on import side-effects.
Diffstat (limited to 'Lib/test/test_cl.py')
-rwxr-xr-xLib/test/test_cl.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/Lib/test/test_cl.py b/Lib/test/test_cl.py
index abfe3c19f5..a2728b7df1 100755
--- a/Lib/test/test_cl.py
+++ b/Lib/test/test_cl.py
@@ -66,7 +66,7 @@ clattrs = ['ADDED_ALGORITHM_ERROR', 'ALAW', 'ALGORITHM_ID',
# This is a very inobtrusive test for the existence of the cl
# module and all its attributes.
-def main():
+def test_main():
# touch all the attributes of al without doing anything
if verbose:
print 'Touching cl module attributes...'
@@ -75,4 +75,7 @@ def main():
print 'touching: ', attr
getattr(cl, attr)
-main()
+
+
+if __name__ == '__main__':
+ test_main()