| OLD | NEW |
| 1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import datetime | 5 import datetime |
| 6 import mock | 6 import mock |
| 7 import pytz | 7 import pytz |
| 8 import unittest | 8 import unittest |
| 9 | 9 |
| 10 from infra_libs.time_functions.testing import mock_datetime_utc, mock_timezone | 10 from infra_libs.time_functions.testing import mock_datetime_utc, mock_timezone |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 @mock_timezone('US/Pacific') | 70 @mock_timezone('US/Pacific') |
| 71 def test_winter_time_is_computed_correctly(self): | 71 def test_winter_time_is_computed_correctly(self): |
| 72 self.assertEqual(datetime.datetime.now(), | 72 self.assertEqual(datetime.datetime.now(), |
| 73 datetime.datetime(2015, 11, 24, 1, 10, 15)) | 73 datetime.datetime(2015, 11, 24, 1, 10, 15)) |
| 74 | 74 |
| 75 @mock_datetime_utc(2015, 8, 24, 9, 10, 15) | 75 @mock_datetime_utc(2015, 8, 24, 9, 10, 15) |
| 76 @mock_timezone('US/Pacific') | 76 @mock_timezone('US/Pacific') |
| 77 def test_summer_time_is_computed_correctly(self): | 77 def test_summer_time_is_computed_correctly(self): |
| 78 self.assertEqual(datetime.datetime.now(), | 78 self.assertEqual(datetime.datetime.now(), |
| 79 datetime.datetime(2015, 8, 24, 2, 10, 15)) | 79 datetime.datetime(2015, 8, 24, 2, 10, 15)) |
| OLD | NEW |