Skip to content

Commit

Permalink
Ensure subscriberClient is not called without auth
Browse files Browse the repository at this point in the history
  • Loading branch information
zechmeister committed Nov 7, 2024
1 parent 501fbf1 commit 87b1407
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.never;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;

import com.fasterxml.jackson.core.JsonProcessingException;
Expand Down Expand Up @@ -89,5 +91,6 @@ void shouldSecureCallbackWithoutAuthorization() {
String.class);

assertEquals(HttpStatus.UNAUTHORIZED.value(), response.getStatusCode().value());
verify(subscriberClient, never()).requestSubmission(any(SubmissionForPickup.class));
}
}

0 comments on commit 87b1407

Please sign in to comment.