Fix testing errors - which surfaced with pytest 6.0.1

This commit is contained in:
Matthias 2020-08-03 19:21:46 +02:00
parent 5ff09a06c7
commit a33346c6b6
2 changed files with 4 additions and 2 deletions

View File

@ -258,7 +258,7 @@ class Exchange:
api.urls['api'] = api.urls['test'] api.urls['api'] = api.urls['test']
logger.info("Enabled Sandbox API on %s", name) logger.info("Enabled Sandbox API on %s", name)
else: else:
logger.warning(name, "No Sandbox URL in CCXT, exiting. " logger.warning(f"No Sandbox URL in CCXT for {name}, exiting. "
"Please check your config.json") "Please check your config.json")
raise OperationalException(f'Exchange {name} does not provide a sandbox api') raise OperationalException(f'Exchange {name} does not provide a sandbox api')

View File

@ -1726,6 +1726,7 @@ def test_update_trade_state_withorderdict(default_conf, trades_for_order, limit_
amount=amount, amount=amount,
exchange='binance', exchange='binance',
open_rate=0.245441, open_rate=0.245441,
open_date=arrow.utcnow().datetime,
fee_open=fee.return_value, fee_open=fee.return_value,
fee_close=fee.return_value, fee_close=fee.return_value,
open_order_id="123456", open_order_id="123456",
@ -1816,6 +1817,7 @@ def test_update_trade_state_sell(default_conf, trades_for_order, limit_sell_orde
open_rate=0.245441, open_rate=0.245441,
fee_open=0.0025, fee_open=0.0025,
fee_close=0.0025, fee_close=0.0025,
open_date=arrow.utcnow().datetime,
open_order_id="123456", open_order_id="123456",
is_open=True, is_open=True,
) )