'The view should redirect to the login page if the user is not logged in.'

def test_login_required(self):

    self.client.logout()
    response = self.client.post(reverse('commerce:checkout_receipt'))
    self.assertEqual(response.status_code, 302)
