def METHOD_NAME(self, test):
    try:
        try:
            test_name = test.__class__.__name__ + "." + test._testMethodName
        except AttributeError:
            # Support for jython 2.1 (__testMethodName is pseudo-private in the test case)
            try:
                test_name = test.__class__.__name__ + "." + test._TestCase__testMethodName
            # Support for class/module exceptions (test is instance of _ErrorHolder)
            except:
                test_name = test.description.split()[1][1:-1] + ' <' + test.description.split()[0] + '>'
    except:
        traceback.print_exc()
        return '<unable to get test name>'
    return test_name