Skip to content

Commit 687b2c7

Browse files
committed
unit test - remove run_all()
1 parent d97b230 commit 687b2c7

File tree

1 file changed

+0
-23
lines changed

1 file changed

+0
-23
lines changed

test/python_tests/utilities.py

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -58,29 +58,6 @@ def get_unique_colors(im):
5858
pixels = sorted(pixels)
5959
return list(map(pixel2rgba, pixels))
6060

61-
62-
def run_all(iterable):
63-
failed = 0
64-
for test in iterable:
65-
try:
66-
test()
67-
sys.stderr.write("\x1b[32m✓ \x1b[m" + test.__name__ + "\x1b[m\n")
68-
except:
69-
exc_type, exc_value, exc_tb = sys.exc_info()
70-
failed += 1
71-
sys.stderr.write("\x1b[31m✘ \x1b[m" + test.__name__ + "\x1b[m\n")
72-
for mline in traceback.format_exception_only(exc_type, exc_value):
73-
for line in mline.rstrip().split("\n"):
74-
sys.stderr.write(" \x1b[31m" + line + "\x1b[m\n")
75-
sys.stderr.write(" Traceback:\n")
76-
for mline in traceback.format_tb(exc_tb):
77-
for line in mline.rstrip().split("\n"):
78-
if not 'utilities.py' in line and not 'trivial.py' in line and not line.strip() == 'test()':
79-
sys.stderr.write(" " + line + "\n")
80-
sys.stderr.flush()
81-
return failed
82-
83-
8461
def side_by_side_image(left_im, right_im):
8562
width = left_im.width() + 1 + right_im.width()
8663
height = max(left_im.height(), right_im.height())

0 commit comments

Comments
 (0)