mirror of
https://github.com/wassname/catalyst.git
synced 2026-09-12 12:12:04 +08:00
MAINT: Moves exchange to utc conversion inside of environment object.
So that the environments' exchange time is used without having to specify it independently. Also, moves uses of Delorean.shift for the exchange conversion inside of environment to use the exchange_dt_to_utc method.
This commit is contained in:
@@ -1033,11 +1033,10 @@ class TestPerformanceTracker(unittest.TestCase):
|
||||
|
||||
def test_minute_tracker(self):
|
||||
""" Tests minute performance tracking."""
|
||||
exc_tz = pytz.timezone('US/Eastern')
|
||||
start_dt = trading.exchange_dt_in_utc(
|
||||
datetime.datetime(2013, 3, 1, 9, 30, tzinfo=exc_tz))
|
||||
end_dt = trading.exchange_dt_in_utc(
|
||||
datetime.datetime(2013, 3, 1, 16, 0, tzinfo=exc_tz))
|
||||
start_dt = trading.environment.exchange_dt_in_utc(
|
||||
datetime.datetime(2013, 3, 1, 9, 30))
|
||||
end_dt = trading.environment.exchange_dt_in_utc(
|
||||
datetime.datetime(2013, 3, 1, 16, 0))
|
||||
|
||||
sim_params = SimulationParameters(
|
||||
period_start=start_dt,
|
||||
|
||||
Reference in New Issue
Block a user