From cf077b15c2b5ab967797e5a604d629a95faf7f7d Mon Sep 17 00:00:00 2001 From: Matthias Date: Sat, 8 Jan 2022 14:54:39 +0100 Subject: [PATCH] Fix random test failure --- tests/exchange/test_ccxt_compat.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tests/exchange/test_ccxt_compat.py b/tests/exchange/test_ccxt_compat.py index 35620e9e2..44c664c92 100644 --- a/tests/exchange/test_ccxt_compat.py +++ b/tests/exchange/test_ccxt_compat.py @@ -19,36 +19,43 @@ from tests.conftest import get_default_conf EXCHANGES = { 'bittrex': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': False, 'timeframe': '1h', }, 'binance': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': True, 'timeframe': '5m', }, 'kraken': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': True, 'timeframe': '5m', }, 'ftx': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': True, 'timeframe': '5m', }, 'kucoin': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': True, 'timeframe': '5m', }, 'gateio': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': True, 'timeframe': '5m', }, 'okex': { 'pair': 'BTC/USDT', + 'stake_currency': 'USDT', 'hasQuoteVolume': True, 'timeframe': '5m', }, @@ -74,8 +81,7 @@ def exchange_conf(): @pytest.fixture(params=EXCHANGES, scope="class") def exchange(request, exchange_conf): exchange_conf['exchange']['name'] = request.param - exchange_conf['stake_currency'] = EXCHANGES[request.param].get( - 'stake_currency', exchange_conf['stake_currency']) + exchange_conf['stake_currency'] = EXCHANGES[request.param]['stake_currency'] exchange = ExchangeResolver.load_exchange(request.param, exchange_conf, validate=True) yield exchange, request.param