File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change 1+ # This file is part of OctoBot (https://github.com/Drakkar-Software/OctoBot)
2+ # Copyright (c) 2022 Drakkar-Software, All rights reserved.
3+ #
4+ # OctoBot is free software; you can redistribute it and/or
5+ # modify it under the terms of the GNU General Public License
6+ # as published by the Free Software Foundation; either
7+ # version 3.0 of the License, or (at your option) any later version.
8+ #
9+ # OctoBot is distributed in the hope that it will be useful,
10+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
11+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12+ # General Public License for more details.
13+ #
14+ # You should have received a copy of the GNU General Public
15+ # License along with OctoBot. If not, see <https://www.gnu.org/licenses/>.
16+ import os
17+
18+ import octobot_trading .exchanges as exchanges
19+
20+
21+ def get_test_exchange_manager (config , exchange_name ):
22+ exchange_manager = exchanges .ExchangeManager (config , exchange_name )
23+ # customize exchange id to include test name (useful in possible memory issues)
24+ exchange_manager .id = f"{ exchange_manager .id } [{ os .environ .get ('PYTEST_CURRENT_TEST' )} ]"
25+ return exchange_manager
You can’t perform that action at this time.
0 commit comments