diff --git a/tests/basics/memoryview2.py b/tests/basics/memoryview2.py index edb7c9e640..4b5af852b2 100644 --- a/tests/basics/memoryview2.py +++ b/tests/basics/memoryview2.py @@ -12,7 +12,3 @@ print(list(memoryview(array('b', [0x7f, -0x80])))) print(list(memoryview(array('B', [0x7f, 0x80, 0x81, 0xff])))) print(list(memoryview(array('h', [0x7f00, -0x8000])))) print(list(memoryview(array('H', [0x7f00, 0x8000, 0x8100, 0xffff])))) - -# these constructors give an internal overflow in uPy -#print(list(memoryview(array('i', [0x7f000000, -0x80000000])))) -#print(list(memoryview(array('I', [0x7f000000, 0x80000000, 0x81000000, 0xffffffff])))) diff --git a/tests/basics/memoryview_intbig.py b/tests/basics/memoryview_intbig.py new file mode 100644 index 0000000000..180f15d186 --- /dev/null +++ b/tests/basics/memoryview_intbig.py @@ -0,0 +1,11 @@ +# test memoryview accessing maximum values for signed/unsigned elements +try: + from array import array + memoryview +except: + import sys + print("SKIP") + sys.exit() + +print(list(memoryview(array('i', [0x7f000000, -0x80000000])))) +print(list(memoryview(array('I', [0x7f000000, 0x80000000, 0x81000000, 0xffffffff]))))