Skip to content

Commit e71fadb

Browse files
author
Robbie Muir
committed
fix test
1 parent e07cceb commit e71fadb

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

linopy/common.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,7 @@ def try_to_convert_to_pd_datetime_index(
137137
if isinstance(coord, xr.DataArray):
138138
index = coord.to_index()
139139
assert isinstance(index, pd.DatetimeIndex)
140+
return index
140141
return pd.DatetimeIndex(coord)
141142
except Exception:
142143
return coord

test/test_variables.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,6 @@ def test_timezone_alignment_with_multiplication() -> None:
141141
series1 = pd.Series(index=utc_index, data=1.0)
142142
var1 = model.add_variables(coords=[utc_index], name="var1")
143143

144-
# TODO increase coverage for datarray when coords are not dataarray
145144
with warnings.catch_warnings():
146145
warnings.simplefilter("error", CoordAlignWarning)
147146
expr = var1 * series1

0 commit comments

Comments
 (0)