// Path: src/main/java/com/github/davidmoten/rx2/flowable/CloseableFlowableWithReset.java
// public final class CloseableFlowableWithReset<T> {
// 
//     private final Flowable<T> flowable;
//     private final Runnable closeAction;
//     private final Runnable resetAction;
// 
//     public CloseableFlowableWithReset(Flowable<T> flowable, Runnable closeAction, Runnable resetAction) {
//         this.flowable = flowable;
//         this.closeAction = closeAction;
//         this.resetAction = resetAction;
//     }
// 
//     public Flowable<T> flowable() {
//         return flowable;
//     }
// 
//     public void reset() {
//         resetAction.run();
//     }
// 
//     public void close() {
//         closeAction.run();
//     }
// 
// }


import io.reactivex.Flowable;
import io.reactivex.annotations.NonNull;
import io.reactivex.functions.Consumer;
import io.reactivex.schedulers.Schedulers;
import org.junit.Test;
import com.github.davidmoten.junit.Asserts;
import com.github.davidmoten.rx2.flowable.CloseableFlowableWithReset;
import org.reactivestreams.Subscription;
import java.util.List;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicInteger;
import static org.junit.Assert.assertTrue;
package com.github.davidmoten.rx2;






public class FlowablesTest {

    @Test
    public void isUtilityClass() {
        Asserts.assertIsUtilityClass(Flowables.class);
    }


    @Test
    public void testCache() {

        final AtomicInteger subscriptionCount = new AtomicInteger(0);

        Flowable<String> source =
                Flowable.just("Alpha", "Beta", "Gamma", "Delta", "Epsilon");

// Path: src/main/java/com/github/davidmoten/rx2/flowable/CloseableFlowableWithReset.java
// public final class CloseableFlowableWithReset<T> {
// 
//     private final Flowable<T> flowable;
//     private final Runnable closeAction;
//     private final Runnable resetAction;
// 
//     public CloseableFlowableWithReset(Flowable<T> flowable, Runnable closeAction, Runnable resetAction) {
//         this.flowable = flowable;
//         this.closeAction = closeAction;
//         this.resetAction = resetAction;
//     }
// 
//     public Flowable<T> flowable() {
//         return flowable;
//     }
// 
//     public void reset() {
//         resetAction.run();
//     }
// 
//     public void close() {
//         closeAction.run();
//     }
// 
// }


// Path: src/test/java/com/github/davidmoten/rx2/FlowablesTest.java
import io.reactivex.Flowable;
import io.reactivex.annotations.NonNull;
import io.reactivex.functions.Consumer;
import io.reactivex.schedulers.Schedulers;
import org.junit.Test;
import com.github.davidmoten.junit.Asserts;
import com.github.davidmoten.rx2.flowable.CloseableFlowableWithReset;
import org.reactivestreams.Subscription;
import java.util.List;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicInteger;
import static org.junit.Assert.assertTrue;

package com.github.davidmoten.rx2;






public class FlowablesTest {

    @Test
    public void isUtilityClass() {
        Asserts.assertIsUtilityClass(Flowables.class);
    }


    @Test
    public void testCache() {

        final AtomicInteger subscriptionCount = new AtomicInteger(0);

        Flowable<String> source =
                Flowable.just("Alpha", "Beta", "Gamma", "Delta", "Epsilon");

        final CloseableFlowableWithReset<List<String>> closeable = Flowables.cache(