    @Test
    void getAccessTokenOnBehalfOfNoAuthenticatedTokenFound() {

        assertThatExceptionOfType(OAuth2ClientException.class)
            .isThrownBy(() -> oAuth2AccessTokenService.getAccessToken(onBehalfOfProperties()))
            .withMessageContaining("no authenticated jwt token found in validation context, cannot do on-behalf-of");
    }