  @Test(expected = PagSeguroLibException.class)
  public void shouldThrowsErrorLib() throws Exception {

    when(httpServletRequest.getParameter("notificationCode")).thenReturn("code");
    when(httpServletRequest.getParameter("notificationType")).thenReturn("type");
    notificationsResource.handle(httpServletRequest, handler);
  }