Skip to content

Commit 66169ef

Browse files
author
Alexander Mancevice
committed
flake8 fixes
1 parent e0384b9 commit 66169ef

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

influxdb/tests/dataframe_client_test.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ def test_multiquery_into_dataframe(self):
251251
"series": [
252252
{
253253
"name": "cpu_load_short",
254-
"columns": ["time","value"],
254+
"columns": ["time", "value"],
255255
"values": [
256256
["2015-01-29T21:55:43.702900257Z", 0.55],
257257
["2015-01-29T21:55:43.702900257Z", 23422],
@@ -263,7 +263,7 @@ def test_multiquery_into_dataframe(self):
263263
"series": [
264264
{
265265
"name": "cpu_load_short",
266-
"columns": ["time","count"],
266+
"columns": ["time", "count"],
267267
"values": [
268268
["1970-01-01T00:00:00Z", 3]
269269
]
@@ -281,16 +281,16 @@ def test_multiquery_into_dataframe(self):
281281
"2015-06-11 20:46:02+0000"])).tz_localize('UTC')
282282
pd2 = pd.DataFrame(
283283
[[3]], columns=['count'],
284-
index=pd.to_datetime(["1970-01-01 00:00:00+00:00"])).tz_localize('UTC')
285-
expected = [{'cpu_load_short':pd1}, {'cpu_load_short':pd2}]
286-
284+
index=pd.to_datetime(["1970-01-01 00:00:00+00:00"]))\
285+
.tz_localize('UTC')
286+
expected = [{'cpu_load_short': pd1}, {'cpu_load_short': pd2}]
287287

288288
cli = DataFrameClient('host', 8086, 'username', 'password', 'db')
289+
iql = "SELECT value FROM cpu_load_short WHERE region='us-west';"\
290+
"SELECT count(value) FROM cpu_load_short WHERE region='us-west'"
289291
with _mocked_session(cli, 'GET', 200, data):
290-
result = cli.query(
291-
"SELECT value FROM cpu_load_short WHERE region='us-west';"\
292-
"SELECT count(value) FROM cpu_load_short WHERE region='us-west'")
293-
for r,e in zip(result, expected):
292+
result = cli.query(iql)
293+
for r, e in zip(result, expected):
294294
for k in e:
295295
assert_frame_equal(e[k], r[k])
296296

0 commit comments

Comments
 (0)