diff options
author | Aaron Meurer <asmeurer@gmail.com> | 2021-07-19 17:25:02 -0600 |
---|---|---|
committer | Aaron Meurer <asmeurer@gmail.com> | 2021-07-19 17:25:02 -0600 |
commit | f20be6ad3239a2e7a611ad42c9b36df7863e9883 (patch) | |
tree | 84cc71b4f1ec0c6934d311ae0c32d1667345a5dc /numpy/_array_api/_array_object.py | |
parent | a566cd1c7110d36d0e7a1f2746ea61e45f49eb89 (diff) | |
download | numpy-f20be6ad3239a2e7a611ad42c9b36df7863e9883.tar.gz |
Start adding tests for the array API submodule
The tests for the module will mostly focus on those things that aren't already
tested by the official array API test suite
(https://github.com/data-apis/array-api-tests). Currently, indexing tests are
added, which test that the Array object correctly rejects otherwise valid
indices that are not required by the array API spec.
Diffstat (limited to 'numpy/_array_api/_array_object.py')
-rw-r--r-- | numpy/_array_api/_array_object.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/numpy/_array_api/_array_object.py b/numpy/_array_api/_array_object.py index 4e3c7b344..54280ef37 100644 --- a/numpy/_array_api/_array_object.py +++ b/numpy/_array_api/_array_object.py @@ -158,7 +158,9 @@ class Array: allowed by NumPy but not required by the array API specification. We always raise ``IndexError`` on such indices (the spec does not require any specific behavior on them, but this makes the NumPy array API - namespace a minimal implementation of the spec). + namespace a minimal implementation of the spec). See + https://data-apis.org/array-api/latest/API_specification/indexing.html + for the full list of required indexing behavior This function either raises IndexError if the index ``key`` is invalid, or a new key to be used in place of ``key`` in indexing. It |