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.

作者 eric.smith
收信人 eric.smith, larry, loewis, mark.dickinson, serhiy.storchaka
日期 2012-05-04.12:28:31
SpamBayes Score -1.0
Marked as misclassified
Message-id <1336134514.24.0.0752833566615.issue14705@psf.upfronthosting.co.za>
In-reply-to
内容
Now that I think about this some more, I think I'd structure the 'p' tests as:

for expr in [False, None, True, 1, 0]:  # add the rest
   self.assertEqual(bool(expr), getargs_p(expr))

Since the salient point is that 'p' returns the same value as bool(), right?

And for the one that raises an exception, you'll have to check that bool and getargs_p both raise the same type of exception.
历史
日期 用户 动作 参数
2012-05-04 12:28:34eric.smith修改recipients: + eric.smith, loewis, mark.dickinson, larry, serhiy.storchaka
2012-05-04 12:28:34eric.smith修改messageid: <1336134514.24.0.0752833566615.issue14705@psf.upfronthosting.co.za>
2012-05-04 12:28:31eric.smith链接issue14705 messages
2012-05-04 12:28:31eric.smith创建