diff --git a/tests/transform/numpy_batch/test_datetime_features.py b/tests/transform/numpy_batch/test_datetime_features.py index c487a25c..c626ec2c 100644 --- a/tests/transform/numpy_batch/test_datetime_features.py +++ b/tests/transform/numpy_batch/test_datetime_features.py @@ -4,16 +4,24 @@ def test_get_date_time_in_pi(): - times = np.array([ - "2020-01-01T00:00:00", "2020-04-01T06:00:00", - "2020-07-01T12:00:00", "2020-09-30T18:00:00", - "2020-12-31T23:59:59", - "2021-01-01T00:00:00", "2021-04-02T06:00:00", - "2021-07-02T12:00:00", "2021-10-01T18:00:00", - "2021-12-31T23:59:59" - ]).reshape((2, 5)) - - expected_times_in_pi = np.array([0, 0.5*np.pi, np.pi, 1.5*np.pi, 2*np.pi] * 2).reshape((2,5)) + times = np.array( + [ + "2020-01-01T00:00:00", + "2020-04-01T06:00:00", + "2020-07-01T12:00:00", + "2020-09-30T18:00:00", + "2020-12-31T23:59:59", + "2021-01-01T00:00:00", + "2021-04-02T06:00:00", + "2021-07-02T12:00:00", + "2021-10-01T18:00:00", + "2021-12-31T23:59:59", + ] + ).reshape((2, 5)) + + expected_times_in_pi = np.array([0, 0.5 * np.pi, np.pi, 1.5 * np.pi, 2 * np.pi] * 2).reshape( + (2, 5) + ) times = times.astype("datetime64[s]")