public void error(String errorCode, String errorDescription, String errorUri) {
        if (Objects.requireNonNull(errorCode).isEmpty())
            throw new IllegalArgumentException("error code must not be empty");
        this.errorCode = errorCode;
        this.errorDescription = errorDescription;
        this.errorUri = errorUri;
        this.token = null;
    }
@Test
    public void testError() {
        String errorCode = "errorCode";
        String errorDescription = "errorDescription";
        String errorUri = "errorUri";
        OAuthBearerTokenCallback callback = new OAuthBearerTokenCallback();
        callback.error(errorCode, errorDescription, errorUri);
        assertEquals(errorCode, callback.errorCode());
        assertEquals(errorDescription, callback.errorDescription());
        assertEquals(errorUri, callback.errorUri());
        assertNull(callback.token());
    }