Code example for InvocationTargetException

Methods: fillInStackTrace, getTargetException

0
                runMethod.invoke(this);
            } 
        } 
        catch (InvocationTargetException e)
        { 
            e.fillInStackTrace();
            throw e.getTargetException();
        } 
        catch (IllegalAccessException e)
        { 
            e.fillInStackTrace();
            throw e;
        } 
        finally 
        { 
            // Take the test end memory and end time and calculate how long it took to run. 
            long endTime = System.nanoTime();
            threadLocalMeasurement.get().endTime = endTime;
            log.debug("startTime = " + threadLocalMeasurement.get().startTime + ", endTime = " + endTime + ", testTime = "
                + getTestTime());