Re: Unit test problem

2008-06-26 Thread Norman Harman
Malcolm Tredinnick wrote: > Status code 302 is an HTTP redirect, which is what you would expect to > see, since your view is always returning a HttpResponseRedirect. The > test framework doesn't follow redirects. What about? assertRedirects(response, expected_url, status_code=302, target_status_

Re: Unit test problem

2008-06-26 Thread Malcolm Tredinnick
On Thu, 2008-06-26 at 00:02 -0700, laspal wrote: > hi, > I am writting unit test for the views. > > class IndustryTest(unittest.TestCase): > > def setUp( self): > self.client = Client() > self.client.post('/ibm/login/', {' usrename' :'admin', > 'password' : 'abcd'}) > > >