Merge branch 'develop' into isort_config
This commit is contained in:
@@ -11,7 +11,8 @@ from freqtrade.data.btanalysis import (BT_DATA_COLUMNS, analyze_trade_parallelis
|
||||
calculate_market_change, calculate_max_drawdown,
|
||||
combine_dataframes_with_mean, create_cum_profit,
|
||||
extract_trades_of_period, get_latest_backtest_filename,
|
||||
load_backtest_data, load_trades, load_trades_from_db)
|
||||
get_latest_hyperopt_file, load_backtest_data, load_trades,
|
||||
load_trades_from_db)
|
||||
from freqtrade.data.history import load_data, load_pair_history
|
||||
from freqtrade.optimize.backtesting import BacktestResult
|
||||
from tests.conftest import create_mock_trades
|
||||
@@ -38,6 +39,17 @@ def test_get_latest_backtest_filename(testdatadir, mocker):
|
||||
get_latest_backtest_filename(testdatadir)
|
||||
|
||||
|
||||
def test_get_latest_hyperopt_file(testdatadir, mocker):
|
||||
res = get_latest_hyperopt_file(testdatadir / 'does_not_exist', 'testfile.pickle')
|
||||
assert res == testdatadir / 'does_not_exist/testfile.pickle'
|
||||
|
||||
res = get_latest_hyperopt_file(testdatadir.parent)
|
||||
assert res == testdatadir.parent / "hyperopt_results.pickle"
|
||||
|
||||
res = get_latest_hyperopt_file(str(testdatadir.parent))
|
||||
assert res == testdatadir.parent / "hyperopt_results.pickle"
|
||||
|
||||
|
||||
def test_load_backtest_data_old_format(testdatadir):
|
||||
|
||||
filename = testdatadir / "backtest-result_test.json"
|
||||
|
Reference in New Issue
Block a user