mirror of
https://github.com/wassname/catalyst.git
synced 2026-08-04 12:45:06 +08:00
BUG: Remove sid entry from open_orders when there are none.
TST: updated tests for new open_orders behavior
This commit is contained in:
@@ -307,11 +307,9 @@ class FinanceTestCase(TestCase):
|
||||
cumulative_pos = tracker.cumulative_performance.positions[sid]
|
||||
self.assertEqual(total_volume, cumulative_pos.amount)
|
||||
|
||||
# the open orders should now be empty
|
||||
# the open orders should not contain sid.
|
||||
oo = blotter.open_orders
|
||||
self.assertTrue(sid in oo)
|
||||
order_list = oo[sid]
|
||||
self.assertEqual(0, len(order_list))
|
||||
self.assertNotIn(sid, oo, "Entry is removed when no open orders")
|
||||
|
||||
def test_blotter_processes_splits(self):
|
||||
sim_params = factory.create_simulation_parameters()
|
||||
|
||||
Reference in New Issue
Block a user