From c17499700f5d293ba65bc163dc3f81a6650de0bd Mon Sep 17 00:00:00 2001 From: Evgeni Burovski Date: Fri, 30 Jan 2026 19:17:29 +0100 Subject: [PATCH] BUG: make test_repeat spec-compliant Its value testing was using xp.full with array fill value, while only python scalars are allowed. Thus, convert fill_value to scalar. --- array_api_tests/test_manipulation_functions.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/array_api_tests/test_manipulation_functions.py b/array_api_tests/test_manipulation_functions.py index 3af7b959..ce29fcde 100644 --- a/array_api_tests/test_manipulation_functions.py +++ b/array_api_tests/test_manipulation_functions.py @@ -372,8 +372,9 @@ def test_repeat(x, kw, data): start = 0 for i, count in enumerate(repeats_array): end = start + count + x_slice_i = dh.get_scalar_type(x.dtype)((x_slice[i])) ph.assert_array_elements("repeat", out=out_slice[start:end], - expected=xp.full((int(count),), x_slice[i], dtype=x.dtype), + expected=xp.full((int(count),), x_slice_i, dtype=x.dtype), kw=kw) start = end