diff --git a/tests/test_history.py b/tests/test_history.py index b86ad1f27f..6b7aec4d42 100644 --- a/tests/test_history.py +++ b/tests/test_history.py @@ -269,6 +269,7 @@ def test_multiple_specs_on_same_bar(self): container.update(bar_data, third_bar_dt) prices = container.get_history(spec, third_bar_dt) no_fill_prices = container.get_history(no_fill_spec, third_bar_dt) + self.assertEqual(prices.values[-1], 10) self.assertTrue(np.isnan(no_fill_prices.values[-1]), "Last price should be np.nan") diff --git a/tests/test_rolling_panel.py b/tests/test_rolling_panel.py index cf45a73436..a8a3e3cf43 100644 --- a/tests/test_rolling_panel.py +++ b/tests/test_rolling_panel.py @@ -91,10 +91,10 @@ def test_alignment(self, env): ) @with_environment() - def test_alignment(self, env): + def test_get_current_multiple_call_same_tick(self, env): """ In old get_current, each call the get_current would copy the data. Thus - changing that object would have no side effects. + changing that object would have no side effects. To keep the same api, make sure that the raw option returns a copy too. """ @@ -129,6 +129,7 @@ def test_alignment(self, env): raw2 = rp.get_current(raw=True) assert data_id(raw) != data_id(raw2) + class TestMutableIndexRollingPanel(unittest.TestCase): def test_basics(self, window=10):