From b9c7d338b39e7a28bf3536bf219b1798c9b5d4e8 Mon Sep 17 00:00:00 2001 From: Yinon Polak Date: Tue, 21 Mar 2023 16:38:05 +0200 Subject: [PATCH] fix test_start_backtesting --- tests/freqai/conftest.py | 3 ++- tests/freqai/test_freqai_interface.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/freqai/conftest.py b/tests/freqai/conftest.py index 02cfdd882..0f29301d0 100644 --- a/tests/freqai/conftest.py +++ b/tests/freqai/conftest.py @@ -1,5 +1,6 @@ from copy import deepcopy from pathlib import Path +from typing import Any, Dict from unittest.mock import MagicMock import pytest @@ -83,7 +84,7 @@ def make_rl_config(conf): return conf -def mock_pytorch_mlp_model_training_parameters(conf): +def mock_pytorch_mlp_model_training_parameters() -> Dict[str, Any]: return { "learning_rate": 3e-4, "trainer_kwargs": { diff --git a/tests/freqai/test_freqai_interface.py b/tests/freqai/test_freqai_interface.py index 5b460cda1..8b126fe55 100644 --- a/tests/freqai/test_freqai_interface.py +++ b/tests/freqai/test_freqai_interface.py @@ -15,7 +15,8 @@ from freqtrade.optimize.backtesting import Backtesting from freqtrade.persistence import Trade from freqtrade.plugins.pairlistmanager import PairListManager from tests.conftest import EXMS, create_mock_trades, get_patched_exchange, log_has_re -from tests.freqai.conftest import get_patched_freqai_strategy, make_rl_config +from tests.freqai.conftest import get_patched_freqai_strategy, make_rl_config, \ + mock_pytorch_mlp_model_training_parameters def is_py11() -> bool: