On 7/10/07, Mambaragi <[EMAIL PROTECTED]> wrote:
> As you see, I view function raises an exception, the exception is
> always regarded as "TemplateDoesNotExist".
> So I have to change the test case to...
>
> ] client = Client()
> ] self.assertRaises(TemplateDoesNotExist, client.get, "/user/
>
On 7/10/07, Mambaragi <[EMAIL PROTECTED]> wrote:
>
> ] client = Client()
> ] self.assertRaises(TemplateDoesNotExist, client.get, "/user/
> preferences/")
>
> Is is a bug or my mistake??
It's a mistake on your part.
assertRaises isn't a very effective test for the test Client, because
web
Hello,
I use django 0.96 and Python 2.5
the following is one of the view functions. I set this function always
raises an LoginRequiredException.
] def preferences(req):
] raise LoginRequiredException, "please, log in"
and the test case.
] client = Client()
]
3 matches
Mail list logo