Improve exception wording

This commit is contained in:
Matthias
2023-09-25 19:48:09 +02:00
parent 9e6cc5ebbd
commit 74709461e3
2 changed files with 8 additions and 1 deletions

View File

@@ -3,12 +3,18 @@ from pathlib import Path
from shutil import copytree
from unittest.mock import PropertyMock
import pytest
from freqtrade.data.converter.trade_converter_kraken import import_kraken_trades_from_csv
from freqtrade.data.history.idatahandler import get_datahandler
from freqtrade.exceptions import OperationalException
from tests.conftest import EXMS, log_has, log_has_re, patch_exchange
def test_import_kraken_trades_from_csv(testdatadir, tmpdir, caplog, default_conf_usdt, mocker):
with pytest.raises(OperationalException, match="This function is only for the kraken exchange"):
import_kraken_trades_from_csv(default_conf_usdt, 'feather')
default_conf_usdt['exchange']['name'] = 'kraken'
patch_exchange(mocker, id='kraken')