Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Tree: e5c0721435
Fetching contributors…

Cannot retrieve contributors at this time

49 lines (44 sloc) 1.159 kB
#!/usr/bin/env python
import os
import sys
reset = ""
def red(text):
red = ""
return "%s%s%s" % (red, text, reset)
def green(text):
green = ""
return "%s%s%s" % (green, text, reset)
def yellow(text):
yellow = ""
return "%s%s%s" % (yellow, text, reset)
def blue(text):
blue = ""
return "%s%s%s" % (blue, text, reset)
def purple(text):
purple = ""
return "%s%s%s" % (purple, text, reset)
def cyan(text):
cyan = ""
return "%s%s%s" % (cyan, text, reset)
sys.path.append(os.getcwd())
def ASSERT(cond, errormsg):
if cond:
print errormsg
print green("\t\t\tPASS")
else:
# COLORS
print >>sys.stderr, errormsg
print red("\t\t\tFAIL")
# TODO Add this to something and continue
# Maybe even raise a token exceptiont o catch so I can
# examine the stack
exit()
def START(test):
# epic kludge
os.current_test = test
print(cyan("== %s ==" % test))
def END():
try:
print(cyan("== %s ==" % os.current_test))
except AttributeError:
ASSERT(False, red("No test in progress"))
Jump to Line
Something went wrong with that request. Please try again.