    @Test
    public void retryWithNoPriorAuth() throws Exception {

        when(accountAuthenticator.getAccessToken()).thenAnswer(invocation -> validAccessToken);

        Response unauthenticatedResponse =
                response.newBuilder()
                        .request(
                                response.request()
                                        .newBuilder()
                                        .removeHeader("Authorization")
                                        .build())
                        .build();
        Request request = requestRetryAuthenticator.authenticate(null, unauthenticatedResponse);

        assertNotNull(request);
        Assert.assertEquals("Bearer " + validAccessToken, request.header("Authorization"));
    }