Removed shorting from tests/optimize/hyperopts/default_hyperopt.py and created another tests/optimize/hyperopts/short_hyperopt.py with long and shorting

This commit is contained in:
Sam Germain
2021-08-23 00:18:56 -06:00
parent 61ad38500a
commit 317a454c0e
3 changed files with 291 additions and 100 deletions

View File

@@ -542,10 +542,6 @@ def test_generate_optimizer(mocker, hyperopt_conf) -> None:
'fastd-value': 35,
'mfi-value': 0,
'rsi-value': 0,
'short-adx-value': 100,
'short-fastd-value': 65,
'short-mfi-value': 100,
'short-rsi-value': 100,
'adx-enabled': False,
'fastd-enabled': True,
'mfi-enabled': False,
@@ -555,10 +551,6 @@ def test_generate_optimizer(mocker, hyperopt_conf) -> None:
'sell-fastd-value': 75,
'sell-mfi-value': 0,
'sell-rsi-value': 0,
'exit-short-adx-value': 100,
'exit-short-fastd-value': 25,
'exit-short-mfi-value': 100,
'exit-short-rsi-value': 100,
'sell-adx-enabled': False,
'sell-fastd-enabled': True,
'sell-mfi-enabled': False,
@@ -585,16 +577,12 @@ def test_generate_optimizer(mocker, hyperopt_conf) -> None:
),
'params_details': {'buy': {'adx-enabled': False,
'adx-value': 0,
'short-adx-value': 100,
'fastd-enabled': True,
'fastd-value': 35,
'short-fastd-value': 65,
'mfi-enabled': False,
'mfi-value': 0,
'short-mfi-value': 100,
'rsi-enabled': False,
'rsi-value': 0,
'short-rsi-value': 100,
'trigger': 'macd_cross_signal'},
'roi': {"0": 0.12000000000000001,
"20.0": 0.02,
@@ -603,16 +591,12 @@ def test_generate_optimizer(mocker, hyperopt_conf) -> None:
'protection': {},
'sell': {'sell-adx-enabled': False,
'sell-adx-value': 0,
'exit-short-adx-value': 100,
'sell-fastd-enabled': True,
'sell-fastd-value': 75,
'exit-short-fastd-value': 25,
'sell-mfi-enabled': False,
'sell-mfi-value': 0,
'exit-short-mfi-value': 100,
'sell-rsi-enabled': False,
'sell-rsi-value': 0,
'exit-short-rsi-value': 100,
'sell-trigger': 'macd_cross_signal'},
'stoploss': {'stoploss': -0.4},
'trailing': {'trailing_only_offset_is_reached': False,