From 4f43e59643cb7a4be7011e27db9f29c905142797 Mon Sep 17 00:00:00 2001 From: Matthias Date: Fri, 21 Jun 2024 16:41:59 +0200 Subject: [PATCH] Add test showing behavior of #10349 --- tests/strategy/test_interface.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/tests/strategy/test_interface.py b/tests/strategy/test_interface.py index d10afd73b..ab87e110e 100644 --- a/tests/strategy/test_interface.py +++ b/tests/strategy/test_interface.py @@ -1,5 +1,6 @@ # pragma pylint: disable=missing-docstring, C0103 import logging +import math from datetime import datetime, timedelta, timezone from pathlib import Path from unittest.mock import MagicMock @@ -536,6 +537,19 @@ def test_min_roi_reached3(default_conf, fee) -> None: ExitType.NONE, lambda **kwargs: None, ), + # Error case - Returning inf. + ( + 0.05, + 0.9, + ExitType.NONE, + None, + False, + True, + 0.09, + 0.9, + ExitType.NONE, + lambda **kwargs: math.inf, + ), ], ) def test_ft_stoploss_reached(