def METHOD_NAME(self):
    methods = ["OPTIONS", "HEAD", "TRACE", "GET", "PUT", "PATCH", "DELETE"]
    url = reverse("autoemails:email_response", args=[1])
    for method in methods:
        with self.subTest(method=method):
            response = self.client.generic(method, path=url)
            self.assertEqual(response.status_code, 405)
    response = self.client.generic("POST", path=url)
    self.assertEqual(response.status_code, 302)  # redirect to log in