test: fix pandas3 test

This commit is contained in:
Matthias
2026-04-12 15:59:26 +02:00
parent cd5ea969c4
commit 412e112c0f
2 changed files with 6 additions and 0 deletions
+3
View File
@@ -860,6 +860,9 @@ def test_backtest_one(default_conf, mocker, testdatadir) -> None:
"funding_fees": [0.0, 0.0],
}
)
# TODO: pandas3 - create correctly above ?!?
expected["open_date"] = expected["open_date"].astype("datetime64[ms, UTC]")
expected["close_date"] = expected["close_date"].astype("datetime64[ms, UTC]")
pd.testing.assert_frame_equal(results, expected)
assert "orders" in results.columns
data_pair = processed[pair]
@@ -83,6 +83,9 @@ def test_backtest_position_adjustment(default_conf, fee, mocker, testdatadir) ->
"funding_fees": [0.0, 0.0],
}
)
# TODO: pandas3 - create correctly above ?!?
expected["open_date"] = expected["open_date"].astype("datetime64[ms, UTC]")
expected["close_date"] = expected["close_date"].astype("datetime64[ms, UTC]")
results_no = results.drop(columns=["orders"])
pd.testing.assert_frame_equal(results_no, expected, check_exact=True)