Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typos in test_buffer.py and update links to numpy issue tracker #118963

Merged
merged 5 commits into from
May 16, 2024
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions Lib/test/test_buffer.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,10 +130,10 @@ def native_type_range(fmt):
for fmt in fmtdict['@']:
fmtdict['@'][fmt] = native_type_range(fmt)

# Format codes suppported by the memoryview object
# Format codes supported by the memoryview object
MEMORYVIEW = NATIVE.copy()

# Format codes suppported by array.array
# Format codes supported by array.array
ARRAY = NATIVE.copy()
for k in NATIVE:
if not k in "bBhHiIlLfd":
Expand Down Expand Up @@ -168,7 +168,6 @@ def randrange_fmt(mode, char, obj):
if char == 'c':
x = bytes([x])
if obj == 'numpy' and x == b'\x00':
# http://projects.scipy.org/numpy/ticket/1925
x = b'\x01'
if char == '?':
x = bool(x)
Expand Down Expand Up @@ -1918,7 +1917,7 @@ def test_ndarray_random(self):
if numpy_array:
shape = t[3]
if 0 in shape:
continue # http://projects.scipy.org/numpy/ticket/1910
continue # https://github.com/numpy/numpy/issues/2503
z = numpy_array_from_structure(items, fmt, t)
self.verify(x, obj=None,
itemsize=z.itemsize, fmt=fmt, readonly=False,
Expand Down Expand Up @@ -1950,7 +1949,7 @@ def test_ndarray_random_invalid(self):
except Exception as e:
numpy_err = e.__class__

if 0: # http://projects.scipy.org/numpy/ticket/1910
if 0: # https://github.com/numpy/numpy/issues/2503
self.assertTrue(numpy_err)

def test_ndarray_random_slice_assign(self):
Expand Down Expand Up @@ -1996,7 +1995,7 @@ def test_ndarray_random_slice_assign(self):

if numpy_array:
if 0 in lshape or 0 in rshape:
continue # http://projects.scipy.org/numpy/ticket/1910
continue # https://github.com/numpy/numpy/issues/2503

zl = numpy_array_from_structure(litems, fmt, tl)
zr = numpy_array_from_structure(ritems, fmt, tr)
Expand Down
Loading