diff --git a/tests/handler/test_http_client.py b/tests/handler/test_http_client.py index e6a6157..4f5cd98 100644 --- a/tests/handler/test_http_client.py +++ b/tests/handler/test_http_client.py @@ -34,6 +34,7 @@ def test_build_headers_default(self, http_client, patched_version_and_sys): "X-Nylas-API-Wrapper": "python", "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", + "Accept-Encoding": "gzip", } def test_build_headers_extra_headers(self, http_client, patched_version_and_sys): @@ -50,6 +51,7 @@ def test_build_headers_extra_headers(self, http_client, patched_version_and_sys) "Authorization": "Bearer test-key", "foo": "bar", "X-Test": "test", + "Accept-Encoding": "gzip", } def test_build_headers_json_body(self, http_client, patched_version_and_sys): @@ -64,6 +66,7 @@ def test_build_headers_json_body(self, http_client, patched_version_and_sys): "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", "Content-type": "application/json", + "Accept-Encoding": "gzip", } def test_build_headers_form_body(self, http_client, patched_version_and_sys): @@ -79,6 +82,7 @@ def test_build_headers_form_body(self, http_client, patched_version_and_sys): "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", "Content-type": "application/x-www-form-urlencoded", + "Accept-Encoding": "gzip", } def test_build_headers_override_headers(self, http_client, patched_version_and_sys): @@ -97,6 +101,7 @@ def test_build_headers_override_headers(self, http_client, patched_version_and_s "Authorization": "Bearer test-key", "foo": "bar", "X-Test": "test", + "Accept-Encoding": "gzip", } def test_build_headers_override_api_key(self, http_client, patched_version_and_sys): @@ -110,6 +115,7 @@ def test_build_headers_override_api_key(self, http_client, patched_version_and_s "X-Nylas-API-Wrapper": "python", "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key-override", + "Accept-Encoding": "gzip", } def test_build_request_default(self, http_client, patched_version_and_sys): @@ -125,6 +131,7 @@ def test_build_request_default(self, http_client, patched_version_and_sys): "X-Nylas-API-Wrapper": "python", "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", + "Accept-Encoding": "gzip", }, } @@ -144,6 +151,7 @@ def test_build_request_override_api_uri(self, http_client, patched_version_and_s "X-Nylas-API-Wrapper": "python", "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", + "Accept-Encoding": "gzip", }, } @@ -201,6 +209,7 @@ def test_execute_download_request_override_timeout( "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", "Content-type": "application/json", + "Accept-Encoding": "gzip", }, timeout=60, stream=False, @@ -291,6 +300,7 @@ def test_execute(self, http_client, patched_version_and_sys, patched_request): "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", "Content-type": "application/json", + "Accept-Encoding": "gzip", "test": "header", }, json={"foo": "bar"}, @@ -319,6 +329,7 @@ def test_execute_override_timeout( "User-Agent": "Nylas Python SDK 2.0.0 - 1.2.3", "Authorization": "Bearer test-key", "Content-type": "application/json", + "Accept-Encoding": "gzip", "test": "header", }, json={"foo": "bar"},