@Test public void throwAsAdapterException_throws_adapter_exception_with_traceid_when_exception_is_runtime_exception() throws Exception { RuntimeException cause = new RuntimeException(); expected.expect(AdapterException.class); expected.expectMessage("traceId x:message1"); expected.expectCause(equalTo(cause)); throwAsAdapterException(new AdapterLogId("x","traceId"),"message1", cause); }
public static void throwAsAdapterException(AdapterLogId id, String message, Throwable t) throws AdapterException { throw asAdapterException(id, message, t); }
AdapterException extends Exception { public static void throwAsAdapterException(AdapterLogId id, String message, Throwable t) throws AdapterException { throw asAdapterException(id, message, t); } }
AdapterException extends Exception { public static void throwAsAdapterException(AdapterLogId id, String message, Throwable t) throws AdapterException { throw asAdapterException(id, message, t); } AdapterException(AdapterLogId id, String message, Throwable cause);  AdapterException(AdapterLogId id, String message);  AdapterException(AdapterLogId id, Throwable cause); }
AdapterException extends Exception { public static void throwAsAdapterException(AdapterLogId id, String message, Throwable t) throws AdapterException { throw asAdapterException(id, message, t); } AdapterException(AdapterLogId id, String message, Throwable cause);  AdapterException(AdapterLogId id, String message);  AdapterException(AdapterLogId id, Throwable cause); static void throwAsAdapterException(AdapterLogId id, String message, Throwable t); static AdapterException asAdapterException(AdapterLogId id, String message, Throwable t); }
AdapterException extends Exception { public static void throwAsAdapterException(AdapterLogId id, String message, Throwable t) throws AdapterException { throw asAdapterException(id, message, t); } AdapterException(AdapterLogId id, String message, Throwable cause);  AdapterException(AdapterLogId id, String message);  AdapterException(AdapterLogId id, Throwable cause); static void throwAsAdapterException(AdapterLogId id, String message, Throwable t); static AdapterException asAdapterException(AdapterLogId id, String message, Throwable t);  }