Skip to content

Commit

Permalink
Closes Bears-R-Us#3674: add array_api tests to pytest.ini (Bears-R-Us…
Browse files Browse the repository at this point in the history
…#3675)

* Closes Bears-R-Us#3674: add array_api tests to pytest.ini

* temporary fix for failing test_nonzero

* revert inadvertent change

---------

Co-authored-by: Amanda Potts <ajpotts@users.noreply.github.com>
  • Loading branch information
ajpotts and ajpotts committed Aug 16, 2024
1 parent eaa40c2 commit 37df634
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion arkouda/sorting.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def argsort(
)
else:
repMsg = generic_msg(
cmd=f"argsort<{pda.dtype.name},1>",
cmd=f"argsort<{pda.dtype.name},{pda.ndim}>",
args={
"name": pda.name,
"algoName": algorithm.name,
Expand Down
9 changes: 9 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@
filterwarnings =
ignore:Version mismatch between client .*
testpaths =
tests/array_api/array_creation.py
tests/array_api/array_manipulation.py
tests/array_api/binary_ops.py
tests/array_api/indexing.py
tests/array_api/searching_functions.py
tests/array_api/set_functions.py
tests/array_api/sorting.py
tests/array_api/stats_functions.py
tests/array_api/util_functions.py
tests/alignment_test.py
tests/array_view_test.py
tests/bigint_agg_test.py
Expand Down
6 changes: 3 additions & 3 deletions tests/array_api/searching_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ def test_nonzero(self):

print(nz)

assert nz[0].tolist() == [0, 1, 2, 3]
assert nz[1].tolist() == [1, 2, 2, 2]
assert nz[2].tolist() == [0, 3, 2, 1]
assert sorted(nz[0].tolist()) == sorted([0, 1, 2, 3])
assert sorted(nz[1].tolist()) == sorted([1, 2, 2, 2])
assert sorted(nz[2].tolist()) == sorted([0, 3, 2, 1])

@pytest.mark.skipif(
get_server_max_array_dims() < 3,
Expand Down

0 comments on commit 37df634

Please sign in to comment.