exchange: fix get_ticker_history test

This commit is contained in:
Samuel Husso 2018-03-26 09:24:50 +03:00
parent 3069a422e9
commit 0a32d38ad9
1 changed files with 3 additions and 2 deletions

View File

@ -205,9 +205,10 @@ def test_get_ticker_history(default_conf, mocker):
tick = 123
api_mock.get_ticker_history = MagicMock(return_value=tick)
mocker.patch('freqtrade.exchange._API', api_mock)
mocker.patch('freqtrade.exchange._API.has', {'fetchOHLCV': True})
mocker.patch('freqtrade.exchange._API.fetch_ohlcv', return_value=tick)
# retrieve original ticker
ticks = get_ticker_history('BTC_ETH', int(default_conf['ticker_interval']))
ticks = get_ticker_history('ETH/BTC', int(default_conf['ticker_interval']))
assert ticks == 123
# change the ticker