Skip to content

Commit 2f9cdbe

Browse files
authored
Merge pull request #66 from honno/pow-skip-neg-exp
Skip testing negative integer exponents for pow related functions
2 parents a214e26 + 39a8df0 commit 2f9cdbe

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

xptests/test_operators_and_elementwise_functions.py

+6
Original file line numberDiff line numberDiff line change
@@ -1267,6 +1267,12 @@ def test_pow(
12671267
):
12681268
left = data.draw(left_strat, label=left_sym)
12691269
right = data.draw(right_strat, label=right_sym)
1270+
if right_is_scalar:
1271+
if isinstance(right, int):
1272+
assume(right >= 0)
1273+
else:
1274+
if dh.is_int_dtype(right.dtype):
1275+
assume(xp.all(right >= 0))
12701276

12711277
try:
12721278
func(left, right)

0 commit comments

Comments
 (0)