Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix test. Use expected result computed by numpy.
  • Loading branch information
sklam committed Mar 14, 2023
commit ae07d34ca74c73a01e40227bf718cca6df91b512
5 changes: 3 additions & 2 deletions numba/tests/test_np_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -2218,11 +2218,12 @@ def test_argpartition_basic(self):
cfunc = jit(nopython=True)(pyfunc)

d = np.array([], dtype=np.int64)
expected = pyfunc(d, 0)
got = cfunc(d, 0)
self.assertPreciseEqual(d, got)
self.assertPreciseEqual(expected, got)

d = np.ones(1, dtype=np.int64)
expected = np.zeros(1, dtype=np.int64)
expected = pyfunc(d, 0)
got = cfunc(d, 0)
self.assertPreciseEqual(expected, got)

Expand Down