Skip to content

Commit b30039d

Browse files
committed
Make flake8 happy.
1 parent cc86bdd commit b30039d

File tree

1 file changed

+9
-14
lines changed

1 file changed

+9
-14
lines changed

pandas/tseries/tests/test_partial_string_indexes.py

+9-14
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,14 @@
1-
import nose
21
import numpy as np
32

43
import pandas.util.testing as tm
5-
from pandas import (
6-
Index, Series, DataFrame, isnull, date_range, Timestamp, Period,
7-
DatetimeIndex, Int64Index, to_datetime, bdate_range, Float64Index,
8-
NaT, timedelta_range, Timedelta, _np_version_under1p8, concat)
4+
from pandas import DataFrame, DatetimeIndex
5+
6+
from pandas.util.testing import assert_frame_equal, assert_series_equal
97

10-
from pandas.util.testing import (
11-
assert_frame_equal, assert_series_equal, assert_almost_equal,
12-
_skip_if_has_locale, slow)
138

149
class TestTimeSeriesPartialSlices(tm.TestCase):
1510
_multiprocess_can_split_ = True
11+
1612
def assert_exact(self, df, ts, value):
1713
element = df['a'][ts]
1814

@@ -23,15 +19,15 @@ def assert_exact(self, df, ts, value):
2319
# Frame should raise (exact match)
2420
self.assertRaises(KeyError, df.__getitem__, ts)
2521

26-
#TODO: test falling to column selection
22+
# TODO: test falling to column selection
2723

28-
def assert_slice(self, df, ts, slice):
24+
def assert_slice(self, df, ts, the_slice):
2925
# Series should return slice
30-
expected = df['a'][slice]
26+
expected = df['a'][the_slice]
3127
assert_series_equal(df['a'][ts], expected)
3228

3329
# Frame should return slice as well
34-
expected = df[slice]
30+
expected = df[the_slice]
3531
assert_frame_equal(df[ts], expected)
3632

3733
def assert_key_error(self, df, ts):
@@ -71,7 +67,6 @@ def test_partial_slices_day(self):
7167
'2012-01-01 00:00:01']:
7268
self.assert_key_error(df, ts)
7369

74-
7570
def test_partial_slice_hour(self):
7671
df = DataFrame({'a': [1, 2, 3]}, DatetimeIndex(['2011-12-31 23',
7772
'2012-01-01 00',
@@ -165,4 +160,4 @@ def test_partial_slice_second(self):
165160
self.assert_slice(df, ts, slice(1, None))
166161

167162
# Not possible to create a string that represents timestamp
168-
# that is more exact then 'second'
163+
# that is more exact then 'second'

0 commit comments

Comments
 (0)