]> granicus.if.org Git - python/commitdiff
Change testdescr.py to use the test_main() approach.
authorGuido van Rossum <guido@python.org>
Thu, 20 Sep 2001 21:39:07 +0000 (21:39 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 20 Sep 2001 21:39:07 +0000 (21:39 +0000)
Lib/test/test_descr.py

index d9c166bb14440f8a939673a4fa0d24819a58947d..fab1e66dadb7034d61bfd1d228ef9f64816b232b 100644 (file)
@@ -1952,7 +1952,7 @@ def coercions():
     coerce(0j, C(0))
 
 
-def all():
+def test_main():
     lists()
     dicts()
     dict_constructor()
@@ -1992,7 +1992,7 @@ def all():
     classic_comparisons()
     rich_comparisons()
     coercions()
+    if verbose: print "All OK"
 
-all()
-
-if verbose: print "All OK"
+if __name__ == "__main__":
+    test_main()