From 205ab26e9225bf8bc0b3d30d68207f30ed0af889 Mon Sep 17 00:00:00 2001 From: Matthias Date: Wed, 24 Aug 2022 20:54:22 +0200 Subject: [PATCH] Remove TODO in test --- tests/test_persistence.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/tests/test_persistence.py b/tests/test_persistence.py index d8973e9d0..2460fde68 100644 --- a/tests/test_persistence.py +++ b/tests/test_persistence.py @@ -2894,8 +2894,8 @@ def test_order_to_ccxt(limit_buy_order_open): (('buy', 100, 9), (200.0, 8.5, 1700.0, 0.0, None, None)), (('sell', 100, 10), (100.0, 8.5, 850.0, 150.0, 150.0, 0.17647059)), (('buy', 150, 11), (250.0, 10, 2500.0, 150.0, 150.0, 0.17647059)), - (('sell', 100, 12), (150.0, 10.0, 1500.0, 350.0, 350.0, 0.2)), - (('sell', 150, 14), (150.0, 10.0, 1500.0, 950.0, 950.0, 0.40)), + (('sell', 100, 12), (150.0, 10.0, 1500.0, 350.0, 200.0, 0.2)), + (('sell', 150, 14), (150.0, 10.0, 1500.0, 950.0, 600.0, 0.40)), ], 'end_profit': 950.0, 'end_profit_ratio': 0.283582, @@ -2960,9 +2960,8 @@ def test_recalc_trade_from_orders_dca(data) -> None: assert trade.amount == result[0] assert trade.open_rate == result[1] assert trade.stake_amount == result[2] - # TODO: enable the below. assert pytest.approx(trade.realized_profit) == result[3] - # assert pytest.approx(trade.close_profit_abs) == result[4] + assert pytest.approx(trade.close_profit_abs) == result[4] assert pytest.approx(trade.close_profit) == result[5] trade.close(price)