This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author zach.ware
Recipients amaury.forgeotdarc, ash, fer_perez, tim.peters, zach.ware
Date 2013-07-17.04:33:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1374035613.52.0.56061299944.issue3158@psf.upfronthosting.co.za>
In-reply-to
Content
In looking at test_decimal for issue16748, I discovered that not all of the doctests for _decimal are being tested.  So, I fixed it (or at least tried to :).

This patch does the following:

- Replace most inspect.isfunction checks in DocTestFinder with inspect.isroutine

- Add a check to DocTestFinder._from_module for method_descriptors

- Correct a doctest on float.fromhex (which is incorrect back to 2.7) due to the new float repr

- Add a couple doctests to the builtins module because previously there were no functions in builtins with docstrings for testing against.  I chose to add to bin(), hex(), and oct(); I believe those three can benefit from having the docstring show the format of the output string.  I'm not terribly attached to those, though, so if anyone has a better suggestion for testing, I'm all ears.

- Add tests using the builtins module (since it's a C module that's definitely going to be available).

- Add doctests to test_builtin (because the tests aren't actually run in test_doctest, just found). While at it, convert test_builtin to unittest.main().  I believe test_builtin should grow doctest running even if the doctests I added to bin, hex, and oct aren't kept; float and int have some doctests that should be kept up to date.

- Add notes to the docs.
History
Date User Action Args
2013-07-17 04:33:33zach.waresetrecipients: + zach.ware, tim.peters, fer_perez, amaury.forgeotdarc, ash
2013-07-17 04:33:33zach.waresetmessageid: <1374035613.52.0.56061299944.issue3158@psf.upfronthosting.co.za>
2013-07-17 04:33:33zach.warelinkissue3158 messages
2013-07-17 04:33:33zach.warecreate