[Python-Dev] unittest's redundant assertions: asserts vs. failIf/Unlesses

Paul Moore p.f.moore at gmail.com
Thu Mar 20 00:05:35 CET 2008


On 19/03/2008, Michael Urman <murman at gmail.com> wrote:
> > OTOH, I'd rather there be OOWTDI so whatever the consensus is is fine
>  > with me.
>
>
> This strikes me as a gratuitous API change of the kind Guido was
>  warning about in his recent post: "Don't change your APIs incompatibly
>  when porting to Py3k"

This seems compelling to me. And as Glyph mentioned, the testing APIs
are the most critical ones to keep working when moving from 2 to 3.

-1 on this change as part of 3.0. Either do it in 2.6 (which wouldn't
satisfy backward compatibility requirements) or defer it to 3.1 or
later. OK, starting 3.0 with deprecated methods is a nuisance, but the
testing framework seems to me to be a valid special case.

Or just don't bother at all. It's not *that* bad.

Paul.


More information about the Python-Dev mailing list