mirror of
https://github.com/msgpack/msgpack-python.git
synced 2025-10-22 13:23:17 +00:00
parent
c3995669f1
commit
b82d0b62f1
2 changed files with 9 additions and 1 deletions
|
@ -96,3 +96,11 @@ def test_bin32_from_byte():
|
|||
|
||||
def test_bin32_from_float():
|
||||
_runtest("f", 2**16, b"\xc6", b"\x00\x01\x00\x00", True)
|
||||
|
||||
|
||||
def test_multidim_memoryview():
|
||||
# See https://github.com/msgpack/msgpack-python/issues/526
|
||||
view = memoryview(b"\00" * 6)
|
||||
data = view.cast(view.format, (3, 2))
|
||||
packed = packb(data)
|
||||
assert packed == b'\xc4\x06\x00\x00\x00\x00\x00\x00'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue