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 jjlee
Recipients
Date 2007-02-25.17:37:23
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
This looks useful.

It would be nice to test failure cases too (e.g. wrong password, .add_password() not called, ...).

I think if this goes into a new file (which might be reasonable), it should be named something like test_urllib2_localnet.py , to allow for adding more loopback tests, which will not always involve proxy handling.  I suppose it should NOT depend on the network resource flag (Lib/test/regrtest.py -u network) since it's only localhost.

Style (see PEP 8):

Don't put whitespace inside brackets -- e.g. bad: fn( arg ) good: fn(arg)

Use this_kind_of_name or thiskind if short, not thisKind.

Imports and classes etc. don't need comments to label them as such.  Probably is useful to label the BaseHTTPServer code though (maybe '# Local proxy test infrastructure').

See e.g. end of Lib/test/test_urllib2net.py for appropriate stdlib test boilerplate.

Your patch has inconsistent line endings, BTW.
History
Date User Action Args
2007-08-23 15:56:43adminlinkissue1667860 messages
2007-08-23 15:56:43admincreate