File tree Expand file tree Collapse file tree 2 files changed +15
-1
lines changed
exchanges/implementations Expand file tree Collapse file tree 2 files changed +15
-1
lines changed Original file line number Diff line number Diff line change @@ -73,6 +73,19 @@ def _tentacles_local_path():
7373 _cleanup ()
7474
7575
76+ @pytest_asyncio .fixture
77+ async def skipped_on_github_CI ():
78+ if _is_on_github_ci ():
79+ pytest .skip (reason = "test skipped on github CI" )
80+
81+
82+ def _is_on_github_ci ():
83+ # Always set to true when GitHub Actions is running the workflow.
84+ # You can use this variable to differentiate when tests are being run locally or by GitHub Actions.
85+ # from https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/store-information-in-variables
86+ return bool (os .getenv ("GITHUB_ACTIONS" ))
87+
88+
7689def _configure_async_test_loop ():
7790 if sys .version_info [0 ] == 3 and sys .version_info [1 ] >= 8 and sys .platform .startswith ('win' ):
7891 # use WindowsSelectorEventLoopPolicy to avoid aiohttp connexion close warnings
Original file line number Diff line number Diff line change 2222import pytest
2323
2424from tests .exchanges import liquid_exchange_manager as liquid_exchange_manager_fixture , DEFAULT_EXCHANGE_NAME
25+ from tests import skipped_on_github_CI
2526
2627# All test coroutines will be treated as marked.
2728pytestmark = pytest .mark .asyncio
@@ -123,7 +124,7 @@ def default_websocket_exchange(liquid_exchange_manager_fixture):
123124 yield MockedWebSocketExchange (liquid_exchange_manager_fixture .config , liquid_exchange_manager_fixture )
124125
125126
126- async def test_start_receive_feeds_and_stop (default_websocket_exchange ):
127+ async def test_start_receive_feeds_and_stop (default_websocket_exchange , skipped_on_github_CI ):
127128 await default_websocket_exchange .init_websocket (
128129 default_websocket_exchange .exchange_manager .exchange_config .traded_time_frames ,
129130 default_websocket_exchange .exchange_manager .exchange_config .traded_symbol_pairs ,
You can’t perform that action at this time.
0 commit comments