Browse souce code repository at: https://github.com/jjYBdx4IL/java-evaluation/blob/master/src/test/java/tests/java/lang/ExceptionTest.java
package tests.java.lang;

import org.junit.Test;

public class ExceptionTest {

    @Test
    public void testStacktrace() {
        Exception ex = new Exception();
        for (StackTraceElement el : ex.getStackTrace()) {
            System.out.println(el.toString());
        }
    }
}
-------------------------------------------------------------------------------
Test set: tests.java.lang.ExceptionTest
-------------------------------------------------------------------------------
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.001 s - in tests.java.lang.ExceptionTest
testStacktrace  Time elapsed: 0 s