[Python-checkins] r78758 - in python/trunk: Lib/test/string_tests.py Lib/test/test_ascii_formatd.py Lib/test/test_fileio.py Lib/test/test_index.py Lib/test/test_random.py Lib/test/test_support.py Lib/test/test_unicode.py Misc/NEWS

Nick Coghlan ncoghlan at gmail.com
Sun Mar 7 13:53:40 CET 2010


florent.xicluna wrote:
> +    Optional argument:
> +     - if 'quiet' is True, it does not fail if a filter catches nothing
> +        (default False)
> +
> +    Without argument, it defaults to:
> +        check_warnings(("", Warning), quiet=False)

The default here needs to be "quiet=True" so that it gives the same
behaviour as the old one if you don't provide any arguments. It doesn't
matter which is more common in our test suite - what matters is that the
old behaviour is documented for use by third parties.

The test_support module documentation also needs to be updated - it's
the only module within the test suite that *is* documented (and thus
constrained by backwards compatibility concerns).
http://docs.python.org/library/test.html#module-test.test_support

It also looks to me like the kwargs.get() calls are missing their
default value for when no 'quiet' argument is provided.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia
---------------------------------------------------------------


More information about the Python-checkins mailing list