Пример #1
0
 @Test
 public void itHasRealmInformation() throws Exception {
   assertThat(Credentials.CHALLENGE.getMetadata().getFirst(HttpHeaders.WWW_AUTHENTICATE))
       .isEqualTo("Basic realm=\"Grendel\"");
 }
Пример #2
0
 @Test
 public void itReturnsA401() throws Exception {
   assertThat(Credentials.CHALLENGE.getStatus()).isEqualTo(Status.UNAUTHORIZED.getStatusCode());
 }