When using assertRedirects, I find myself doing an assert redirects, then wanting to validate the text where I'm redirecting. The process seems a little clunky and an assertRedirectContains would be useful.
Current process:
self.assertRedirects(response, '/confirm/', status_code=302, target_status_code=200)
response = self.client.get('/confirm/')
self.assertContains(response, "Total = $54.50", count=1, status_code=200)
It would be nice to have something like:
self.assertRedirectContains(response, "Total = $54.50", count=1, status_code=302, target_status_code=200)
I'm assuming there's no other shortcut I'm missing.
*** UPDATE (from russellm) ***
Rather that assertRedirectContains, I'm favouring a modification to the test client that will follow redirects. Details in the comment below