diff options
author | Josh Wilson <person142@users.noreply.github.com> | 2020-06-07 20:48:23 -0700 |
---|---|---|
committer | Josh Wilson <person142@users.noreply.github.com> | 2020-06-07 22:44:06 -0700 |
commit | 2e238e411a4875d470a40cd0c351056ca30882ed (patch) | |
tree | e28ed20952fd86844ca1ba0c833ff41aea4951ac | |
parent | 4b5f00e228eb62305302e1f3862c2c93d2abe075 (diff) | |
download | numpy-2e238e411a4875d470a40cd0c351056ca30882ed.tar.gz |
MAINT: avoid more division by zero in typing test causing aarch64 to fail
-rw-r--r-- | numpy/tests/typing/pass/simple.py | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/numpy/tests/typing/pass/simple.py b/numpy/tests/typing/pass/simple.py index b4b42ca0c..e0157ab81 100644 --- a/numpy/tests/typing/pass/simple.py +++ b/numpy/tests/typing/pass/simple.py @@ -5,7 +5,7 @@ import numpy as np from typing import Iterable # noqa: F401 # Basic checks -array = np.array([2, 3]) +array = np.array([1, 2]) def ndarray_func(x): @@ -125,21 +125,22 @@ array * 1 1 * array array *= 1 +nonzero_array = np.array([1, 2]) array / 1 -1 / array +1 / nonzero_array float_array = np.array([1.0, 2.0]) float_array /= 1 array // 1 -1 // array +1 // nonzero_array array //= 1 array % 1 -1 % array +1 % nonzero_array array %= 1 divmod(array, 1) -divmod(1, array) +divmod(1, nonzero_array) array ** 1 1 ** array |