Skip to content

Commit 0fb851f

Browse files
committed
Removed redundant optional_dtypes strategy
1 parent 3f6e330 commit 0fb851f

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

array_api_tests/test_creation_functions.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111
from hypothesis.strategies import integers, floats, one_of, none, booleans, just, shared, composite
1212

1313

14-
optional_dtypes = none() | shared_dtypes
15-
shared_optional_dtypes = shared(optional_dtypes, key="optional_dtype")
16-
17-
1814
int_range = integers(-MAX_ARRAY_SIZE, MAX_ARRAY_SIZE)
1915
float_range = floats(-MAX_ARRAY_SIZE, MAX_ARRAY_SIZE,
2016
allow_nan=False)
@@ -95,7 +91,7 @@ def test_empty_like(x, kw):
9591
assert out.dtype == x.dtype, f"{x.dtype=!s}, but empty_like() returned an array with dtype {out.dtype}"
9692
else:
9793
assert out.dtype == dtype, f"{dtype=!s}, but empty_like() returned an array with dtype {out.dtype}"
98-
assert out.shape == x.shape, "empty_like() produced an array with an incorrect shape"
94+
assert out.shape == x.shape, f"{x.shape=}, but empty_like() returned an array with shape {out.shape}"
9995

10096

10197
# TODO: Use this method for all optional arguments

0 commit comments

Comments
 (0)