Testing warnings

0 views
Skip to first unread message

Jeremy Dunck

unread,
Nov 4, 2009, 8:19:08 PM11/4/09
to django-d...@googlegroups.com
I'm preparing a patch to make querysets call warnings.warn
if .iterator is used multiple times on a single qs.

I don't see any examples of verification of warnings in the current
test suite. Any suggestions on how best to test this?

Alex Gaynor

unread,
Nov 4, 2009, 8:21:31 PM11/4/09
to django-d...@googlegroups.com
Warnings should just go to stdout (or perhaps stderr) in any event it
should be similar to picking up on a print statement wouldn't they?

Alex

--
"I disapprove of what you say, but I will defend to the death your
right to say it." -- Voltaire
"The people's good is the highest law." -- Cicero
"Code can always be simpler than you think, but never as simple as you
want" -- Me
Reply all
Reply to author
Forward
0 new messages