diff options
author | Eric Wieser <wieser.eric@gmail.com> | 2019-10-15 20:51:24 +0100 |
---|---|---|
committer | Eric Wieser <wieser.eric@gmail.com> | 2019-10-15 21:49:20 +0100 |
commit | c75756a85be29fc7889c003deb28a4250b8d4487 (patch) | |
tree | 60fa888e08e528ad47cfb7f81b3b6e374cbad7b3 /numpy/core/tests | |
parent | a0a680150d4ac8c2ec8e1202646b733c4e348e3e (diff) | |
download | numpy-c75756a85be29fc7889c003deb28a4250b8d4487.tar.gz |
BUG: Default start to 0 for timedelta arange
Before this change, it would confusingly default to NaT, which was not useful.
Fixes gh-14713
Diffstat (limited to 'numpy/core/tests')
-rw-r--r-- | numpy/core/tests/test_datetime.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/core/tests/test_datetime.py b/numpy/core/tests/test_datetime.py index f99c0f72b..a10e6dbe0 100644 --- a/numpy/core/tests/test_datetime.py +++ b/numpy/core/tests/test_datetime.py @@ -1831,7 +1831,7 @@ class TestDateTime(object): def test_timedelta_arange_no_dtype(self): d = np.array(5, dtype="m8[D]") assert_equal(np.arange(d, d + 1), d) - assert_raises(ValueError, np.arange, d) + assert_equal(np.arange(d), np.arange(0, d)) def test_datetime_maximum_reduce(self): a = np.array(['2010-01-02', '1999-03-14', '1833-03'], dtype='M8[D]') |