mirror of
https://github.com/freqtrade/freqtrade.git
synced 2024-11-14 04:03:55 +00:00
Add test for successful_buys
This commit is contained in:
parent
b5c4f9ebe2
commit
f5848ea891
|
@ -84,9 +84,11 @@ def test_strategy_updater_method_params(default_conf, caplog) -> None:
|
||||||
instance_strategy_updater = StrategyUpdater()
|
instance_strategy_updater = StrategyUpdater()
|
||||||
modified_code = instance_strategy_updater.update_code("""
|
modified_code = instance_strategy_updater.update_code("""
|
||||||
def confirm_trade_exit(sell_reason: str):
|
def confirm_trade_exit(sell_reason: str):
|
||||||
|
nr_orders = trades.nr_of_successful_buys
|
||||||
pass
|
pass
|
||||||
""")
|
""")
|
||||||
assert "exit_reason" in modified_code
|
assert "exit_reason" in modified_code
|
||||||
|
assert "nr_orders = trades.nr_of_successful_entries" in modified_code
|
||||||
|
|
||||||
|
|
||||||
def test_strategy_updater_dicts(default_conf, caplog) -> None:
|
def test_strategy_updater_dicts(default_conf, caplog) -> None:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user