django-test-utils
django-test-utils copied to clipboard
Submit and cookies
Hello Eric, I try using twill to my tests but I am unable to successfully submit form via POST as logged user. Look at this code:
login(username="myusername", password="mypassword") go('/myurl/') fv(2, 'continue', '') submit()
problem
logout()
If I print show_cookies() I get different value before and after submit. On this test I want to check, if application return the same page with form together with error messages due to mandatory form fields. But all I get is login page (because POST don't set cookies, and my code put redirection to login page).