Assert { public static <T> T unreachableCode() { unreachableCode(null, (Object[]) null); return null; }  static T assertNotNull(T object); static T assertNotNull(T object, String message, Object...args); static T assertNotNull(T object, ExceptionType exceptionType, String message, Object...args); static T assertNull(T object); static T assertNull(T object, String message, Object...args); static T assertNull(T object, ExceptionType exceptionType, String message, Object...args); static void assertTrue(boolean expression); static void assertTrue(boolean expression, String message, Object...args); static void assertTrue(boolean expression, ExceptionType exceptionType, String message, Object...args); static T unreachableCode(); static T unreachableCode(String message, Object...args); static T unexpectedException(Throwable e); static T unexpectedException(Throwable e, String message, Object...args); static T fail(); static T fail(String message, Object...args); static T unsupportedOperation(); static T unsupportedOperation(String message, Object...args);  }
@Test public void unreachableCode() { try { Assert.unreachableCode(); } catch (UnreachableCodeException e) { assertThat(e, exception(UnreachableCodeException.class, DEFAULT_HEADER, "unreachable")); } try { Assert.unreachableCode(MESSAGE); } catch (UnreachableCodeException e) { assertThat(e, exception(UnreachableCodeException.class, MESSAGE)); } try { Assert.unreachableCode(MESSAGE, 1); } catch (UnreachableCodeException e) { assertThat(e, exception(UnreachableCodeException.class, MESSAGE_1)); } }