From 6a5feacd38cd3e7748cc2c8269420b762c5b8ee6 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sat, 19 Oct 2024 13:32:27 +0200 Subject: [PATCH] tests: Skip binanceus websocket tests binance.us volume is currently too low for this test to run reliably. --- tests/exchange_online/conftest.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tests/exchange_online/conftest.py b/tests/exchange_online/conftest.py index d942323bd..e9c594299 100644 --- a/tests/exchange_online/conftest.py +++ b/tests/exchange_online/conftest.py @@ -73,6 +73,7 @@ EXCHANGES = { "hasQuoteVolume": True, "timeframe": "1h", "futures": False, + "skip_ws_tests": True, "sample_order": [ { "symbol": "SOLUSDT", @@ -423,14 +424,17 @@ def exchange_mode(request): def exchange_ws(request, exchange_conf, exchange_mode, class_mocker): class_mocker.patch("freqtrade.exchange.bybit.Bybit.additional_exchange_init") exchange_conf["exchange"]["enable_ws"] = True + exchange_param = EXCHANGES[request.param] + if exchange_param.get("skip_ws_tests"): + pytest.skip(f"{request.param} does not support websocket tests.") if exchange_mode == "spot": exchange, name = get_exchange(request.param, exchange_conf) - pair = EXCHANGES[request.param]["pair"] - elif EXCHANGES[request.param].get("futures"): + pair = exchange_param["pair"] + elif exchange_param.get("futures"): exchange, name = get_futures_exchange( request.param, exchange_conf, class_mocker=class_mocker ) - pair = EXCHANGES[request.param]["futures_pair"] + pair = exchange_param["futures_pair"] else: pytest.skip("Exchange does not support futures.")