Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jdt-dev] Stacktrace of the tests

Hi all,

When a test fails on Jenkins, let's say CleanUpTest.testStaticInnerClass(), we only know the type of the exception and the line in the test:
CleanUpTest.testStaticInnerClass:15296->CleanUpTestCase.assertGroupCategoryUsed:213 ยป ClassCast

Would it be possible to configure JUnit to log the whole stacktrace?


For now, I'm locally adding this:
        try {
            ...
        } catch (Exception e) {
            StringWriter sw = new StringWriter();
            PrintWriter pw = new PrintWriter(sw);
            e.printStackTrace(pw);
            fail(sw.toString());
        }

Best regards,
Fabrice TIERCELIN

Back to the top