On Fri, Dec 24, 2010 at 12:56 PM, Will Hardy <e.willha...@gmail.com> wrote:

> Maybe we could add a keyword argument to Django's TestCase.assert*()
> methods that raises an AssertionError instead of failing the test when the
> method's condition is not met (I assume that the test should error instead
> of failing).
>
> eg:
>
> self.assertEqual(1, 1, test_assumption=True)
>
> Cheers,
>
> Will
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers" group.
> To post to this group, send email to django-develop...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-developers+unsubscr...@googlegroups.com<django-developers%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
> http://groups.google.com/group/django-developers?hl=en.
>

Maybe I'm doing testing fundamentally wrong but i don't really care if a
test failed or had an exception, I treat them the same, some bug needs to be
fixed.  To that end I prefer writing everything using the assert* methods on
TestCase, they give more informative error messages.

Alex

-- 
"I disapprove of what you say, but I will defend to the death your right to
say it." -- Evelyn Beatrice Hall (summarizing 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

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-develop...@googlegroups.com.
To unsubscribe from this group, send email to 
django-developers+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en.

Reply via email to