Merge branch 'additionalColumnOnCountTable' into develop-berlinguyinca
This commit is contained in:
commit
c665ed9ef3
@ -357,8 +357,9 @@ class Telegram(RPC):
|
|||||||
|
|
||||||
message = tabulate({
|
message = tabulate({
|
||||||
'current': [len(trades)],
|
'current': [len(trades)],
|
||||||
'max': [self._config['max_open_trades']]
|
'max': [self._config['max_open_trades']],
|
||||||
}, headers=['current', 'max'], tablefmt='simple')
|
'total stake': [sum((trade.open_rate * trade.amount) for trade in trades)]
|
||||||
|
}, headers=['current', 'max', 'total stake'], tablefmt='simple')
|
||||||
message = "<pre>{}</pre>".format(message)
|
message = "<pre>{}</pre>".format(message)
|
||||||
logger.debug(message)
|
logger.debug(message)
|
||||||
self.send_msg(message, parse_mode=ParseMode.HTML)
|
self.send_msg(message, parse_mode=ParseMode.HTML)
|
||||||
|
@ -1001,9 +1001,12 @@ def test_count_handle(default_conf, update, ticker, mocker) -> None:
|
|||||||
msg_mock.reset_mock()
|
msg_mock.reset_mock()
|
||||||
telegram._count(bot=MagicMock(), update=update)
|
telegram._count(bot=MagicMock(), update=update)
|
||||||
|
|
||||||
msg = '<pre> current max\n--------- -----\n 1 {}</pre>'.format(
|
msg = '<pre> current max total stake\n--------- ----- -------------\n' \
|
||||||
default_conf['max_open_trades']
|
' 1 {} {}</pre>'\
|
||||||
)
|
.format(
|
||||||
|
default_conf['max_open_trades'],
|
||||||
|
default_conf['stake_amount']
|
||||||
|
)
|
||||||
assert msg in msg_mock.call_args_list[0][0][0]
|
assert msg in msg_mock.call_args_list[0][0][0]
|
||||||
|
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ jsonschema==2.6.0
|
|||||||
numpy==1.14.3
|
numpy==1.14.3
|
||||||
TA-Lib==0.4.17
|
TA-Lib==0.4.17
|
||||||
pytest==3.5.1
|
pytest==3.5.1
|
||||||
pytest-mock==1.9.0
|
pytest-mock==1.10.0
|
||||||
pytest-cov==2.5.1
|
pytest-cov==2.5.1
|
||||||
hyperopt==0.1
|
hyperopt==0.1
|
||||||
# do not upgrade networkx before this is fixed https://github.com/hyperopt/hyperopt/issues/325
|
# do not upgrade networkx before this is fixed https://github.com/hyperopt/hyperopt/issues/325
|
||||||
|
Loading…
Reference in New Issue
Block a user