def METHOD_NAME(passed, fatal):
    global failed
    with open(summary_file, 'a+') as summary:
        print(bool(passed), file=summary)
        if (not passed):
            failed = True
            print('!!! test failed:', file=summary)
            for s in inspect.stack()[2:]:
                print("!!!  %s:%i" % (s[1], s[2]), file=summary)
                print("!!! %s" % s[4][0], file=summary)
                if re.match('\W*t_\w+\.py$', s[1]):
                    break
            print('!!! ', file=summary)
            if fatal:
                exit(1)