This commit is contained in:
Ichinga Samuel
2024-11-10 12:25:50 +01:00
parent d9bd84bc2e
commit f56d0c85b3
39 changed files with 1538 additions and 1179 deletions
+6
View File
@@ -144,6 +144,12 @@ class TestBackTestEngine:
assert acc.margin_free == 62.5
assert acc.margin_level == 2600
def test_account_sync(self):
balance = 200
self.bte.setup_account_sync(balance=balance)
acc = self.bte.get_account_info()
assert acc.balance == balance
async def test_bte2_init(self, bte2):
assert bte2._data.fully_loaded is True
assert bte2.span == self.bte.span
+1 -1
View File
@@ -25,6 +25,6 @@ class TestPositions:
async def test_get_position_by_symbol(self):
symbol = self.positions.positions[0].symbol
positions = await self.positions.get_position_by_symbol(symbol=symbol)
positions = await self.positions.get_positions_by_symbol(symbol=symbol)
assert len(positions) >= 0
assert positions[0].symbol == symbol