Skip to content

Commit

Permalink
reformatted with black
Browse files Browse the repository at this point in the history
  • Loading branch information
jrmylow committed Nov 24, 2023
1 parent 61ce977 commit 1d57c56
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion pandas/core/arrays/datetimes.py
Original file line number Diff line number Diff line change
Expand Up @@ -2761,7 +2761,7 @@ def _generate_range(
if offset.n >= 0:
start = offset.rollforward(start) # type: ignore[assignment]
else:
start = offset.rollback(start) # type: ignore[assignment]
start = offset.rollback(start) # type: ignore[assignment]

# Unsupported operand types for < ("Timestamp" and "None")
if periods is None and end < start and offset.n >= 0: # type: ignore[operator]
Expand Down
10 changes: 5 additions & 5 deletions pandas/tests/indexes/datetimes/test_date_range.py
Original file line number Diff line number Diff line change
Expand Up @@ -1536,8 +1536,8 @@ def test_date_range_year_end(self, unit):
def test_date_range_partial_day_year_end(self, unit):
# GH#56134
rng = date_range(
start = "2021-12-31 00:00:01",
end = "2023-10-31 00:00:00",
start="2021-12-31 00:00:01",
end="2023-10-31 00:00:00",
freq="YE",
unit=unit,
)
Expand All @@ -1560,8 +1560,8 @@ def test_date_range_negative_freq_year_end(self, unit):
def test_date_range_negative_freq_year_end_inbounds(self, unit):
# GH#56147
rng = date_range(
start = "2023-10-31 00:00:00",
end = "2021-10-31 00:00:00",
start="2023-10-31 00:00:00",
end="2021-10-31 00:00:00",
freq="-1YE",
unit=unit,
)
Expand All @@ -1570,7 +1570,7 @@ def test_date_range_negative_freq_year_end_inbounds(self, unit):
dtype=f"M8[{unit}]",
freq="-1YE",
)
tm.assert_index_equal(rng, exp)
tm.assert_index_equal(rng, exp)

def test_date_range_business_year_end_year(self, unit):
# see GH#9313
Expand Down

0 comments on commit 1d57c56

Please sign in to comment.