Skip to content

Commit 38aa697

Browse files
committed
Fully address i|q|l ambiguity (hopefully).
1 parent 3f04188 commit 38aa697

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tests/test_buffers.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ def test_format_descriptor_format(cpp_name, expected_fmts, np_array_dtype):
5151
# py::format_descriptor<> vs np.array:
5252
na = np.array([], dtype=np_array_dtype)
5353
bi = m.get_buffer_info(na)
54-
if fmt == "q":
55-
assert bi.format in ["q", "l"]
56-
elif fmt == "Q":
57-
assert bi.format in ["Q", "L"]
54+
if fmt in ("i", "q"):
55+
assert bi.format in [fmt, "l"]
56+
elif fmt in ("I", "Q"):
57+
assert bi.format in [fmt, "L"]
5858
else:
5959
assert bi.format == fmt
6060

0 commit comments

Comments
 (0)