mirror of
https://github.com/licsber/micropython.git
synced 2024-09-20 00:50:24 +08:00
tests/extmod/framebuf_polygon.py: Replace sys.stdout.write with print.
So the test doesn't depend on the `sys` module. Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
parent
7211bafb33
commit
40687451bb
@ -1,5 +1,3 @@
|
||||
import sys
|
||||
|
||||
try:
|
||||
import framebuf
|
||||
from array import array
|
||||
@ -18,8 +16,8 @@ def print_buffer(buffer, width, height):
|
||||
for row in range(height):
|
||||
for col in range(width):
|
||||
val = buffer[(row * width) + col]
|
||||
sys.stdout.write(" {:02x}".format(val) if val else " ··")
|
||||
sys.stdout.write("\n")
|
||||
print(" {:02x}".format(val) if val else " ··", end="")
|
||||
print()
|
||||
|
||||
|
||||
buf = bytearray(70 * 70)
|
||||
|
Loading…
Reference in New Issue
Block a user