StackTraceProvider { public String getStackTrace(final Throwable throwable) { return ExceptionUtils.getStackTrace(throwable); }  String getStackTrace(final Throwable throwable);  }
@Test public void shouldGetTheStackTraceOfAnExceptionAsAString() throws Exception { final String stackTrace = stackTraceProvider.getStackTrace(new Exception("Ooops")); final String stackTracePrefix = "java.lang.Exception: Ooops\n" + "\tat uk.gov.justice.services.framework.utilities.exceptions.StackTraceProviderTest.shouldGetTheStackTraceOfAnExceptionAsAString(StackTraceProviderTest.java"; assertThat(stackTrace.startsWith(stackTracePrefix), is(true)); }