Joe Gregorio
2013-05-13 11:28:56 -04:00
parent 28f34e7c12
commit c02f563842
2 changed files with 3 additions and 2 deletions

View File

@@ -141,7 +141,7 @@ class BaseModel(Model):
headers['user-agent'] += ' '
else:
headers['user-agent'] = ''
headers['user-agent'] += 'google-api-python-client/' + __version__
headers['user-agent'] += 'google-api-python-client/%s (gzip)' % __version__
if body_value is not None:
headers['content-type'] = self.content_type

View File

@@ -140,7 +140,8 @@ class Model(unittest.TestCase):
headers, path_params, query_params, body)
self.assertEqual(headers['user-agent'],
'my-test-app/1.23.4 google-api-python-client/' + __version__)
'my-test-app/1.23.4 google-api-python-client/' + __version__ +
' (gzip)')
def test_bad_response(self):
model = JsonModel(data_wrapper=False)