package com.github.ryber.mocks;

public class Result {
    private final int status;
    private final String content;
    private final String redirect;
    private final Exception thrownException;

    public Result(Exception e){
        status = 500;
        content = e.getLocalizedMessage();
        redirect = null;
        thrownException = e;
    }

    public Result(MockResponse response){
        status = response.getStatus();
        content = response.getOutputString();
        redirect = response.getRedirectLocation();
        thrownException = null;
    }

    public String getContent() {
        return content;
    }

    public int getStatus() {
        return status;
    }

    public String getRedirect() {
        return redirect;
    }
}

@@ -755,11 +755,94 @@
 t;%0A    %7D
+%0A%0A    public Exception getThrownException() %7B%0A        return thrownException;%0A    %7D
 %0A%7D%0A

add getter for exceptions