Skip to content

Commit

Permalink
Adapt test to use Binance class
Browse files Browse the repository at this point in the history
  • Loading branch information
xmatthias committed Aug 25, 2019
1 parent defa1c0 commit 067c122
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions freqtrade/tests/test_freqtradebot.py
Original file line number Diff line number Diff line change
Expand Up @@ -2414,7 +2414,7 @@ def test_may_execute_sell_after_stoploss_on_exchange_hit(default_conf,

mocker.patch('freqtrade.exchange.Exchange.symbol_amount_prec', lambda s, x, y: y)
mocker.patch('freqtrade.exchange.Exchange.symbol_price_prec', lambda s, x, y: y)
mocker.patch('freqtrade.exchange.Exchange.stoploss_limit', stoploss_limit)
mocker.patch('freqtrade.exchange.Binance.stoploss_limit', stoploss_limit)

freqtrade = FreqtradeBot(default_conf)
freqtrade.strategy.order_types['stoploss_on_exchange'] = True
Expand Down Expand Up @@ -2454,7 +2454,6 @@ def test_may_execute_sell_after_stoploss_on_exchange_hit(default_conf,
freqtrade.process_maybe_execute_sell(trade)
assert trade.stoploss_order_id is None
assert trade.is_open is False
print(trade.sell_reason)
assert trade.sell_reason == SellType.STOPLOSS_ON_EXCHANGE.value
assert rpc_mock.call_count == 2

Expand Down

0 comments on commit 067c122

Please sign in to comment.