Update trade response to use a single Order object
This commit is contained in:
@@ -109,14 +109,13 @@ def test_rpc_trade_status(default_conf, ticker, fee, mocker) -> None:
|
||||
'stoploss_entry_dist_ratio': -0.10448878,
|
||||
'open_order': None,
|
||||
'exchange': 'binance',
|
||||
'filled_entry_orders': [{
|
||||
'orders': [{
|
||||
'amount': 91.07468123, 'average': 1.098e-05, 'safe_price': 1.098e-05,
|
||||
'cost': 0.0009999999999054, 'filled': 91.07468123, 'ft_order_side': 'buy',
|
||||
'order_date': ANY, 'order_timestamp': ANY, 'order_filled_date': ANY,
|
||||
'order_filled_timestamp': ANY, 'order_type': 'limit', 'price': 1.098e-05,
|
||||
'is_open': False, 'pair': 'ETH/BTC', 'order_id': ANY,
|
||||
'remaining': ANY, 'status': ANY}],
|
||||
'filled_exit_orders': []
|
||||
}
|
||||
|
||||
mocker.patch('freqtrade.exchange.Exchange.get_rate',
|
||||
@@ -184,14 +183,13 @@ def test_rpc_trade_status(default_conf, ticker, fee, mocker) -> None:
|
||||
'stoploss_entry_dist_ratio': -0.10448878,
|
||||
'open_order': None,
|
||||
'exchange': 'binance',
|
||||
'filled_entry_orders': [{
|
||||
'orders': [{
|
||||
'amount': 91.07468123, 'average': 1.098e-05, 'safe_price': 1.098e-05,
|
||||
'cost': 0.0009999999999054, 'filled': 91.07468123, 'ft_order_side': 'buy',
|
||||
'order_date': ANY, 'order_timestamp': ANY, 'order_filled_date': ANY,
|
||||
'order_filled_timestamp': ANY, 'order_type': 'limit', 'price': 1.098e-05,
|
||||
'is_open': False, 'pair': 'ETH/BTC', 'order_id': ANY,
|
||||
'remaining': ANY, 'status': ANY}],
|
||||
'filled_exit_orders': []
|
||||
}
|
||||
|
||||
|
||||
|
@@ -902,8 +902,7 @@ def test_api_status(botclient, mocker, ticker, fee, markets):
|
||||
'buy_tag': None,
|
||||
'timeframe': 5,
|
||||
'exchange': 'binance',
|
||||
'filled_entry_orders': [],
|
||||
'filled_exit_orders': [],
|
||||
'orders': [ANY],
|
||||
|
||||
}
|
||||
|
||||
@@ -1092,6 +1091,7 @@ def test_api_forcebuy(botclient, mocker, fee):
|
||||
'buy_tag': None,
|
||||
'timeframe': 5,
|
||||
'exchange': 'binance',
|
||||
'orders': [],
|
||||
}
|
||||
|
||||
|
||||
|
@@ -203,7 +203,7 @@ def test_telegram_status(default_conf, update, mocker) -> None:
|
||||
'stop_loss_ratio': -0.0001,
|
||||
'open_order': '(limit buy rem=0.00000000)',
|
||||
'is_open': True,
|
||||
'filled_entry_orders': []
|
||||
'orders': []
|
||||
}]),
|
||||
)
|
||||
|
||||
|
@@ -901,8 +901,7 @@ def test_to_json(default_conf, fee):
|
||||
'buy_tag': None,
|
||||
'timeframe': None,
|
||||
'exchange': 'binance',
|
||||
'filled_entry_orders': [],
|
||||
'filled_exit_orders': []
|
||||
'orders': [],
|
||||
}
|
||||
|
||||
# Simulate dry_run entries
|
||||
@@ -970,8 +969,7 @@ def test_to_json(default_conf, fee):
|
||||
'buy_tag': 'buys_signal_001',
|
||||
'timeframe': None,
|
||||
'exchange': 'binance',
|
||||
'filled_entry_orders': [],
|
||||
'filled_exit_orders': []
|
||||
'orders': [],
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user