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 terry.reedy
Recipients kbk, roger.serwy, serhiy.storchaka, terry.reedy
Date 2014-01-10.01:45:09
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1389318310.78.0.911028361013.issue20122@psf.upfronthosting.co.za>
In-reply-to
Content
The existing tests in CallTips.py, half of which I wrote based on the ones that existed, have one or two deficiencies that are copied in the patch.

First, they are not proper unittests. They test get_argspec indirectly by calling .fetch_tip and get_entity. This lead to the new private parameter, which will not be needed for the existing tests when get_argspec is called directly with objects.

Adding more tests for get_entity, beyond the one in test_calltips.py already, is a different issue. The function is mostly a wrapper for eval(), which we may assume works correctly.

Second, the doubling resulting from putting expected output in docstrings seems a bit flakey. It certainly does not test cases with no docstring or multiple-line docstrings.

I am working on a revised patch. (Also, the unittest call was added with test_calltip.py and I want it left.)

In 2.7. get_argspec is get_arg_text, with a different implementation. Backporting to 2.7 will require some adjustments.
History
Date User Action Args
2014-01-10 01:45:10terry.reedysetrecipients: + terry.reedy, kbk, roger.serwy, serhiy.storchaka
2014-01-10 01:45:10terry.reedysetmessageid: <1389318310.78.0.911028361013.issue20122@psf.upfronthosting.co.za>
2014-01-10 01:45:10terry.reedylinkissue20122 messages
2014-01-10 01:45:09terry.reedycreate