Skip to content

Commit 29494e1

Browse files
Update test_minimum_maximum_out_deprecated
1 parent a893287 commit 29494e1

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

dpnp/tests/test_mathematical.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2912,11 +2912,13 @@ def test_elemenwise_outer_scalar():
29122912
assert dpnp.allclose(result, expected)
29132913

29142914

2915+
@testing.with_requires("numpy>=2.4")
2916+
@pytest.mark.parametrize("xp", [dpnp, numpy])
29152917
@pytest.mark.parametrize("func", ["minimum", "maximum"])
2916-
def test_minimum_maximum_out_deprecated(func):
2917-
a = dpnp.array([1, 3, 2])
2918-
b = dpnp.array([2, 2, 2])
2919-
out = dpnp.empty_like(a)
2918+
def test_minimum_maximum_out_deprecated(xp, func):
2919+
a = xp.array([1, 3, 2])
2920+
b = xp.array([2, 2, 2])
2921+
out = xp.empty_like(a)
29202922

29212923
with pytest.warns(DeprecationWarning, match="deprecated"):
2922-
_ = getattr(dpnp, func)(a, b, out)
2924+
_ = getattr(xp, func)(a, b, out)

0 commit comments

Comments
 (0)