Skip to content

Commit e439225

Browse files
author
Logan Riggs
committed
pep
1 parent 240db7c commit e439225

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

tabpy/tabpy_server/app/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ def run(self):
9797
raise RuntimeError(msg)
9898

9999
settings = {}
100-
if self.settings[SettingsParameters.GzipEnabled] == True:
100+
if self.settings[SettingsParameters.GzipEnabled] is True:
101101
settings["decompress_request"] = True
102102
application.listen(
103103
self.settings[SettingsParameters.Port],

tests/integration/integ_test_base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ def _get_url(self) -> str:
272272
url = "http://"
273273
url += "localhost:" + self._get_port()
274274
return url
275-
275+
276276
def _get_connection(self) -> http.client.HTTPConnection:
277277
protocol = self._get_transfer_protocol()
278278
url = "localhost:" + self._get_port()

tests/integration/test_gzip.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
import os
99
import requests
1010

11+
1112
class TestEvaluate(integ_test_base.IntegTestBase):
1213
def _get_config_file_name(self) -> str:
1314
"""
@@ -70,7 +71,8 @@ def test_single_value_returned(self):
7071
}
7172

7273
url = self._get_url() + "/evaluate"
73-
response = requests.request("POST", url, data=gzip.compress(payload.encode('utf-8')), headers=headers)
74+
response = requests.request("POST", url, data=gzip.compress(payload.encode('utf-8')),
75+
headers=headers)
7476
result = json.loads(response.text)
7577

7678
self.assertEqual(200, response.status_code)
@@ -90,7 +92,8 @@ def test_syntax_error(self):
9092
}
9193

9294
url = self._get_url() + "/evaluate"
93-
response = requests.request("POST", url, data=gzip.compress(payload.encode('utf-8')), headers=headers)
95+
response = requests.request("POST", url, data=gzip.compress(payload.encode('utf-8')),
96+
headers=headers)
9497
result = json.loads(response.text)
9598

9699
self.assertEqual(500, response.status_code)

tests/unit/server_tests/test_service_info_handler.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,8 @@ def test_given_server_with_auth_expect_correct_info_response(self):
101101
features = v1["features"]
102102
self.assertDictEqual(
103103
{"authentication": {"methods": {"basic-auth": {}}, "required": True},
104-
'evaluate_enabled': True, 'gzip_enabled': True},
105-
features,
104+
'evaluate_enabled': True, 'gzip_enabled': True},
105+
features,
106106
)
107107

108108

0 commit comments

Comments
 (0)