Commit 929f06c5 authored by Raymond Hettinger's avatar Raymond Hettinger

Minor cleanups.

parent 4c530130
...@@ -200,7 +200,6 @@ Check 1200 is for $120.15 ...@@ -200,7 +200,6 @@ Check 1200 is for $120.15
Check 1201 is for $764.05 Check 1201 is for $764.05
Check 1202 is for $823.14 Check 1202 is for $823.14
>>> import operator
>>> import operator >>> import operator
>>> for cube in imap(operator.pow, xrange(1,4), repeat(3)): >>> for cube in imap(operator.pow, xrange(1,4), repeat(3)):
... print cube ... print cube
...@@ -303,7 +302,6 @@ False ...@@ -303,7 +302,6 @@ False
>>> dotproduct([1,2,3], [4,5,6]) >>> dotproduct([1,2,3], [4,5,6])
32 32
""" """
__test__ = {'libreftest' : libreftest} __test__ = {'libreftest' : libreftest}
...@@ -312,7 +310,6 @@ def test_main(verbose=None): ...@@ -312,7 +310,6 @@ def test_main(verbose=None):
test_support.run_unittest(TestBasicOps) test_support.run_unittest(TestBasicOps)
# verify reference counting # verify reference counting
import sys
if verbose and hasattr(sys, "gettotalrefcount"): if verbose and hasattr(sys, "gettotalrefcount"):
counts = [None] * 5 counts = [None] * 5
for i in xrange(len(counts)): for i in xrange(len(counts)):
...@@ -321,8 +318,7 @@ def test_main(verbose=None): ...@@ -321,8 +318,7 @@ def test_main(verbose=None):
print counts print counts
# doctest the examples in the library reference # doctest the examples in the library reference
import doctest test_support.run_doctest(sys.modules[__name__], verbose)
doctest.testmod(sys.modules[__name__])
if __name__ == "__main__": if __name__ == "__main__":
test_main(verbose=True) test_main(verbose=True)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment