@ -32,6 +32,11 @@ class ElasticMock:
class LiveBase:
@classmethod
def tearDownClass(cls):
cls.account.client.close_all_positions()
super(LiveBase, cls).tearDownClass()
def setUpClass(cls):
super(LiveBase, cls).setUpClass()
@ -78,3 +78,8 @@ class LiveTradingTestCase(ElasticMock, LiveBase, TestCase):
if not found:
self.fail("Could not find the trade in the list of open trades")
def test_convert_open_trades(self):
"""
Test converting open trades response to Trade-like format.