Skip to content

Commit 491c459

Browse files
author
Marco Gorelli
committed
Remove duplicated tests
1 parent e5545a7 commit 491c459

File tree

1 file changed

+0
-33
lines changed

1 file changed

+0
-33
lines changed

pandas/tests/series/test_datetime_values.py

-33
Original file line numberDiff line numberDiff line change
@@ -378,39 +378,6 @@ def test_dt_other_accessors(self, accessor):
378378
expected = getattr(datetimes.dt, accessor)
379379
tm.assert_series_equal(result, expected)
380380

381-
def test_dt_tz_localize(self, tz_aware_fixture):
382-
# GH 27952
383-
tz = tz_aware_fixture
384-
datetimes = pd.Series(
385-
["2019-01-01", "2019-01-01", "2019-01-02"], dtype="datetime64[ns]"
386-
)
387-
categorical = datetimes.astype("category")
388-
result = categorical.dt.tz_localize(tz)
389-
expected = datetimes.dt.tz_localize(tz)
390-
tm.assert_series_equal(result, expected)
391-
392-
def test_dt_tz_convert(self, tz_aware_fixture):
393-
# GH 27952
394-
tz = tz_aware_fixture
395-
datetimes = pd.Series(
396-
["2019-01-01", "2019-01-01", "2019-01-02"], dtype="datetime64[ns, MET]"
397-
)
398-
categorical = datetimes.astype("category")
399-
result = categorical.dt.tz_convert(tz)
400-
expected = datetimes.dt.tz_convert(tz)
401-
tm.assert_series_equal(result, expected)
402-
403-
@pytest.mark.parametrize("accessor", ["year", "month", "day"])
404-
def test_dt_other_accessors(self, accessor):
405-
# GH 27952
406-
datetimes = pd.Series(
407-
["2018-01-01", "2018-01-01", "2019-01-02"], dtype="datetime64[ns]"
408-
)
409-
categorical = datetimes.astype("category")
410-
result = getattr(categorical.dt, accessor)
411-
expected = getattr(datetimes.dt, accessor)
412-
tm.assert_series_equal(result, expected)
413-
414381
def test_dt_accessor_no_new_attributes(self):
415382
# https://github.com/pandas-dev/pandas/issues/10673
416383
s = Series(date_range("20130101", periods=5, freq="D"))

0 commit comments

Comments
 (0)