@Nullable Throwable maybeError() {
    Object maybeError = delegate.getAttribute("error");
    if (maybeError instanceof Throwable) return (Throwable) maybeError;
    maybeError = delegate.getAttribute(RequestDispatcher.ERROR_EXCEPTION);
    if (maybeError instanceof Throwable) return (Throwable) maybeError;
    return null;
  }
@Test void maybeError_badRequestAttribute() {
    when(request.getAttribute("error")).thenReturn(new Object());

    assertThat(wrapper.maybeError()).isNull();
  }