public static <T> RetryTransformer<T> of(Retry retry) {
        return new RetryTransformer<>(retry);
    }
@Test
    public void returnOnCompleteUsingCompletable() throws InterruptedException {
        RetryConfig config = retryConfig();
        Retry retry = Retry.of("testName", config);
        RetryTransformer<Object> retryTransformer = RetryTransformer.of(retry);
        doNothing()
            .doThrow(new HelloWorldException())
            .doThrow(new HelloWorldException())
            .doNothing()
            .when(helloWorldService).sayHelloWorld();
        Completable.fromRunnable(helloWorldService::sayHelloWorld)
            .compose(retryTransformer)
            .test()
            .await()
            .assertNoValues()
            .assertComplete();
        Completable.fromRunnable(helloWorldService::sayHelloWorld)
            .compose(retryTransformer)
            .test()
            .await()
            .assertNoValues()
            .assertComplete();

        then(helloWorldService).should(times(4)).sayHelloWorld();

        Retry.Metrics metrics = retry.getMetrics();
        assertThat(metrics.getNumberOfSuccessfulCallsWithoutRetryAttempt()).isEqualTo(1);
        assertThat(metrics.getNumberOfSuccessfulCallsWithRetryAttempt()).isEqualTo(1);
        assertThat(metrics.getNumberOfFailedCallsWithRetryAttempt()).isZero();
        assertThat(metrics.getNumberOfFailedCallsWithoutRetryAttempt()).isZero();
    }