def testGenerateHeadUrl(self):
    self._RunAsync(self.object_store.Put, self.key, 'foo')

    url = self.object_store.GenerateUrl(self.key, method='HEAD', expires_in=100)
    response = httpclient.HTTPClient().fetch(url, method='HEAD', request_timeout=3.0)
    self.assertEqual(response.code, 200)
    self.assertEqual(response.headers['Content-Length'], '3')
The debug error template should be shown only if DEBUG is True
dataset/ETHPy150Open viewfinderco/viewfinder/backend/storage/test/s3_object_store_test.py/S3ObjectStoreTestCase.testGenerateHeadUrl--crossover with--dataset/ETHPy150Open dcramer/django-compositepks/tests/regressiontests/comment_tests/tests/comment_view_tests.py/CommentViewTests.testDebugCommentErrors