The following issues were found

src/test/java/io/reactivex/rxjava3/internal/operators/maybe/MaybeFlattenTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 26

              public class MaybeFlattenTest extends RxJavaTest {

    @Test
    public void dispose() {
        TestHelper.checkDisposed(Maybe.just(1).flatMap(new Function<Integer, MaybeSource<Integer>>() {
            @Override
            public MaybeSource<Integer> apply(Integer v) throws Exception {
                return Maybe.just(2);
            }

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 36

                  }

    @Test
    public void doubleOnSubscribe() {
        TestHelper.checkDoubleOnSubscribeMaybe(new Function<Maybe<Integer>, MaybeSource<Integer>>() {
            @Override
            public MaybeSource<Integer> apply(Maybe<Integer> v) throws Exception {
                return v.flatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 51

                  }

    @Test
    public void mainError() {
        Maybe.<Integer>error(new TestException())
        .flatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        return Maybe.just(2);

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 64

                  }

    @Test
    public void mainEmpty() {
        Maybe.<Integer>empty()
        .flatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        return Maybe.just(2);

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 77

                  }

    @Test
    public void mapperThrows() {
        Maybe.just(1)
        .flatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        throw new TestException();

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 90

                  }

    @Test
    public void mapperReturnsNull() {
        Maybe.just(1)
        .flatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        return null;

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 18

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.exceptions.TestException;
import io.reactivex.rxjava3.functions.Function;
import io.reactivex.rxjava3.testsupport.TestHelper;

public class MaybeFlattenTest extends RxJavaTest {

            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/operators/maybe/MaybeConcatMapTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 26

              public class MaybeConcatMapTest extends RxJavaTest {

    @Test
    public void dispose() {
        TestHelper.checkDisposed(Maybe.just(1).concatMap(new Function<Integer, MaybeSource<Integer>>() {
            @Override
            public MaybeSource<Integer> apply(Integer v) throws Exception {
                return Maybe.just(2);
            }

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 36

                  }

    @Test
    public void doubleOnSubscribe() {
        TestHelper.checkDoubleOnSubscribeMaybe(new Function<Maybe<Integer>, MaybeSource<Integer>>() {
            @Override
            public MaybeSource<Integer> apply(Maybe<Integer> v) throws Exception {
                return v.concatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 51

                  }

    @Test
    public void mainError() {
        Maybe.<Integer>error(new TestException())
        .concatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        return Maybe.just(2);

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 64

                  }

    @Test
    public void mainEmpty() {
        Maybe.<Integer>empty()
        .concatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        return Maybe.just(2);

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 77

                  }

    @Test
    public void mapperThrows() {
        Maybe.just(1)
        .concatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        throw new TestException();

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 90

                  }

    @Test
    public void mapperReturnsNull() {
        Maybe.just(1)
        .concatMap(new Function<Integer, MaybeSource<Integer>>() {
                    @Override
                    public MaybeSource<Integer> apply(Integer v) throws Exception {
                        return null;

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 18

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.exceptions.TestException;
import io.reactivex.rxjava3.functions.Function;
import io.reactivex.rxjava3.testsupport.TestHelper;

public class MaybeConcatMapTest extends RxJavaTest {

            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/operators/flowable/FlowableIntervalTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 29

              public class FlowableIntervalTest extends RxJavaTest {

    @Test
    public void cancel() {
        Flowable.interval(1, TimeUnit.MILLISECONDS, Schedulers.trampoline())
        .take(10)
        .test()
        .assertResult(0L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L);
    }

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 30

              
    @Test
    public void cancel() {
        Flowable.interval(1, TimeUnit.MILLISECONDS, Schedulers.trampoline())
        .take(10)
        .test()
        .assertResult(0L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L);
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 30

              
    @Test
    public void cancel() {
        Flowable.interval(1, TimeUnit.MILLISECONDS, Schedulers.trampoline())
        .take(10)
        .test()
        .assertResult(0L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L);
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 30

              
    @Test
    public void cancel() {
        Flowable.interval(1, TimeUnit.MILLISECONDS, Schedulers.trampoline())
        .take(10)
        .test()
        .assertResult(0L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L);
    }


            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 37

                  }

    @Test
    public void badRequest() {
        TestHelper.assertBadRequestReported(Flowable.interval(1, TimeUnit.MILLISECONDS, Schedulers.trampoline()));
    }

    @Test
    public void cancelledOnRun() {

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 42

                  }

    @Test
    public void cancelledOnRun() {
        TestSubscriber<Long> ts = new TestSubscriber<>();
        IntervalSubscriber is = new IntervalSubscriber(ts);
        ts.onSubscribe(is);

        is.cancel();

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 20

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.internal.operators.flowable.FlowableInterval.IntervalSubscriber;
import io.reactivex.rxjava3.schedulers.Schedulers;
import io.reactivex.rxjava3.subscribers.TestSubscriber;
import io.reactivex.rxjava3.testsupport.TestHelper;


            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/operators/completable/CompletableTimerTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 32

              public class CompletableTimerTest extends RxJavaTest {

    @Test
    public void dispose() {
        TestHelper.checkDisposed(Completable.timer(1, TimeUnit.SECONDS, new TestScheduler()));
    }

    @Test
    public void timerInterruptible() throws Exception {

            

Reported by PMD.

A method/constructor should not explicitly throw java.lang.Exception
Design

Line: 37

                  }

    @Test
    public void timerInterruptible() throws Exception {
        ScheduledExecutorService exec = Executors.newSingleThreadScheduledExecutor();
        try {
            for (Scheduler s : new Scheduler[] { Schedulers.single(), Schedulers.computation(), Schedulers.newThread(), Schedulers.io(), Schedulers.from(exec, true) }) {
                final AtomicBoolean interrupted = new AtomicBoolean();
                TestObserver<Void> to = Completable.timer(1, TimeUnit.MILLISECONDS, s)

            

Reported by PMD.

Avoid instantiating new objects inside loops
Performance

Line: 41

                      ScheduledExecutorService exec = Executors.newSingleThreadScheduledExecutor();
        try {
            for (Scheduler s : new Scheduler[] { Schedulers.single(), Schedulers.computation(), Schedulers.newThread(), Schedulers.io(), Schedulers.from(exec, true) }) {
                final AtomicBoolean interrupted = new AtomicBoolean();
                TestObserver<Void> to = Completable.timer(1, TimeUnit.MILLISECONDS, s)
                .doOnComplete(new Action() {
                    @Override
                    public void run() throws Exception {
                        try {

            

Reported by PMD.

Avoid instantiating new objects inside loops
Performance

Line: 43

                          for (Scheduler s : new Scheduler[] { Schedulers.single(), Schedulers.computation(), Schedulers.newThread(), Schedulers.io(), Schedulers.from(exec, true) }) {
                final AtomicBoolean interrupted = new AtomicBoolean();
                TestObserver<Void> to = Completable.timer(1, TimeUnit.MILLISECONDS, s)
                .doOnComplete(new Action() {
                    @Override
                    public void run() throws Exception {
                        try {
                        Thread.sleep(3000);
                        } catch (InterruptedException ex) {

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 61

              
                Thread.sleep(500);

                assertTrue(s.getClass().getSimpleName(), interrupted.get());
            }
        } finally {
            exec.shutdown();
        }
    }

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 23

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.functions.Action;
import io.reactivex.rxjava3.observers.TestObserver;
import io.reactivex.rxjava3.schedulers.*;
import io.reactivex.rxjava3.testsupport.TestHelper;


            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.schedulers'
Design

Line: 26

              import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.functions.Action;
import io.reactivex.rxjava3.observers.TestObserver;
import io.reactivex.rxjava3.schedulers.*;
import io.reactivex.rxjava3.testsupport.TestHelper;

public class CompletableTimerTest extends RxJavaTest {

    @Test

            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/operators/completable/CompletableSubscribeOnTest.java
7 issues
Potential violation of Law of Demeter (method chain calls)
Design

Line: 39

                      try {
            TestScheduler scheduler = new TestScheduler();

            TestObserver<Void> to = Completable.complete()
            .subscribeOn(scheduler)
            .test();

            scheduler.advanceTimeBy(1, TimeUnit.SECONDS);


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 39

                      try {
            TestScheduler scheduler = new TestScheduler();

            TestObserver<Void> to = Completable.complete()
            .subscribeOn(scheduler)
            .test();

            scheduler.advanceTimeBy(1, TimeUnit.SECONDS);


            

Reported by PMD.

Potential violation of Law of Demeter (object not created locally)
Design

Line: 45

              
            scheduler.advanceTimeBy(1, TimeUnit.SECONDS);

            to.assertResult();

            assertTrue(list.toString(), list.isEmpty());
        } finally {
            RxJavaPlugins.reset();
        }

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 54

                  }

    @Test
    public void dispose() {
        TestHelper.checkDisposed(PublishSubject.create().ignoreElements().subscribeOn(new TestScheduler()));
    }

    @Test
    public void doubleOnSubscribe() {

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 59

                  }

    @Test
    public void doubleOnSubscribe() {
        TestHelper.checkDoubleOnSubscribeCompletable(new Function<Completable, CompletableSource>() {
            @Override
            public CompletableSource apply(Completable c) throws Exception {
                return c.subscribeOn(Schedulers.single());
            }

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 23

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.functions.Function;
import io.reactivex.rxjava3.observers.TestObserver;
import io.reactivex.rxjava3.plugins.RxJavaPlugins;
import io.reactivex.rxjava3.schedulers.*;
import io.reactivex.rxjava3.subjects.PublishSubject;

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.schedulers'
Design

Line: 27

              import io.reactivex.rxjava3.functions.Function;
import io.reactivex.rxjava3.observers.TestObserver;
import io.reactivex.rxjava3.plugins.RxJavaPlugins;
import io.reactivex.rxjava3.schedulers.*;
import io.reactivex.rxjava3.subjects.PublishSubject;
import io.reactivex.rxjava3.testsupport.TestHelper;

public class CompletableSubscribeOnTest extends RxJavaTest {


            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/operators/observable/ObservableCountTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 25

              public class ObservableCountTest extends RxJavaTest {

    @Test
    public void dispose() {
        TestHelper.checkDisposed(Observable.just(1).count());

        TestHelper.checkDisposed(Observable.just(1).count().toObservable());
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void dispose() {
        TestHelper.checkDisposed(Observable.just(1).count());

        TestHelper.checkDisposed(Observable.just(1).count().toObservable());
    }

    @Test

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 28

                  public void dispose() {
        TestHelper.checkDisposed(Observable.just(1).count());

        TestHelper.checkDisposed(Observable.just(1).count().toObservable());
    }

    @Test
    public void doubleOnSubscribe() {
        TestHelper.checkDoubleOnSubscribeObservable(new Function<Observable<Object>, ObservableSource<Long>>() {

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 28

                  public void dispose() {
        TestHelper.checkDisposed(Observable.just(1).count());

        TestHelper.checkDisposed(Observable.just(1).count().toObservable());
    }

    @Test
    public void doubleOnSubscribe() {
        TestHelper.checkDoubleOnSubscribeObservable(new Function<Observable<Object>, ObservableSource<Long>>() {

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 32

                  }

    @Test
    public void doubleOnSubscribe() {
        TestHelper.checkDoubleOnSubscribeObservable(new Function<Observable<Object>, ObservableSource<Long>>() {
            @Override
            public ObservableSource<Long> apply(Observable<Object> o) throws Exception {
                return o.count().toObservable();
            }

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 36

                      TestHelper.checkDoubleOnSubscribeObservable(new Function<Observable<Object>, ObservableSource<Long>>() {
            @Override
            public ObservableSource<Long> apply(Observable<Object> o) throws Exception {
                return o.count().toObservable();
            }
        });

        TestHelper.checkDoubleOnSubscribeObservableToSingle(new Function<Observable<Object>, SingleSource<Long>>() {
            @Override

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 18

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.functions.Function;
import io.reactivex.rxjava3.testsupport.TestHelper;

public class ObservableCountTest extends RxJavaTest {


            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/jdk8/ObservableFromOptionalTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 25

              public class ObservableFromOptionalTest extends RxJavaTest {

    @Test
    public void hasValue() {
        Observable.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void hasValue() {
        Observable.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }

    @Test

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void hasValue() {
        Observable.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }

    @Test

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 32

                  }

    @Test
    public void empty() {
        Observable.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 33

              
    @Test
    public void empty() {
        Observable.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }

}

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 33

              
    @Test
    public void empty() {
        Observable.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }

}

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 20

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;

public class ObservableFromOptionalTest extends RxJavaTest {

    @Test
    public void hasValue() {

            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/jdk8/MaybeFromOptionalTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 25

              public class MaybeFromOptionalTest extends RxJavaTest {

    @Test
    public void hasValue() {
        Maybe.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void hasValue() {
        Maybe.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }

    @Test

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void hasValue() {
        Maybe.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }

    @Test

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 32

                  }

    @Test
    public void empty() {
        Maybe.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 33

              
    @Test
    public void empty() {
        Maybe.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }

}

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 33

              
    @Test
    public void empty() {
        Maybe.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }

}

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 20

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;

public class MaybeFromOptionalTest extends RxJavaTest {

    @Test
    public void hasValue() {

            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/internal/jdk8/FlowableFromOptionalTest.java
7 issues
JUnit tests should include assert() or fail()
Design

Line: 25

              public class FlowableFromOptionalTest extends RxJavaTest {

    @Test
    public void hasValue() {
        Flowable.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void hasValue() {
        Flowable.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }

    @Test

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 26

              
    @Test
    public void hasValue() {
        Flowable.fromOptional(Optional.of(1))
        .test()
        .assertResult(1);
    }

    @Test

            

Reported by PMD.

JUnit tests should include assert() or fail()
Design

Line: 32

                  }

    @Test
    public void empty() {
        Flowable.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }


            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 33

              
    @Test
    public void empty() {
        Flowable.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }

}

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 33

              
    @Test
    public void empty() {
        Flowable.fromOptional(Optional.empty())
        .test()
        .assertResult();
    }

}

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 20

              
import org.junit.Test;

import io.reactivex.rxjava3.core.*;

public class FlowableFromOptionalTest extends RxJavaTest {

    @Test
    public void hasValue() {

            

Reported by PMD.

src/test/java/io/reactivex/rxjava3/flowable/FlowableEventStream.java
7 issues
Found non-transient, non-static member. Please mark as transient or provide accessors.
Error

Line: 53

                  }

    static final class EventConsumer implements Consumer<Emitter<Event>> {
        private final String type;
        private final int numInstances;

        EventConsumer(String type, int numInstances) {
            this.type = type;
            this.numInstances = numInstances;

            

Reported by PMD.

Found non-transient, non-static member. Please mark as transient or provide accessors.
Error

Line: 54

              
    static final class EventConsumer implements Consumer<Emitter<Event>> {
        private final String type;
        private final int numInstances;

        EventConsumer(String type, int numInstances) {
            this.type = type;
            this.numInstances = numInstances;
        }

            

Reported by PMD.

Potential violation of Law of Demeter (method chain calls)
Design

Line: 68

                              // slow it down somewhat
                Thread.sleep(50);
            } catch (InterruptedException e) {
                Thread.currentThread().interrupt();
                s.onError(e);
            }
        }
    }


            

Reported by PMD.

Found non-transient, non-static member. Please mark as transient or provide accessors.
Error

Line: 75

                  }

    public static class Event {
        public final String type;
        public final String instanceId;
        public final Map<String, Object> values;

        /**
         * Construct an event with the provided parameters.

            

Reported by PMD.

Found non-transient, non-static member. Please mark as transient or provide accessors.
Error

Line: 76

              
    public static class Event {
        public final String type;
        public final String instanceId;
        public final Map<String, Object> values;

        /**
         * Construct an event with the provided parameters.
         * @param type the event type

            

Reported by PMD.

Found non-transient, non-static member. Please mark as transient or provide accessors.
Error

Line: 77

                  public static class Event {
        public final String type;
        public final String instanceId;
        public final Map<String, Object> values;

        /**
         * Construct an event with the provided parameters.
         * @param type the event type
         * @param instanceId the instance identifier

            

Reported by PMD.

Avoid unused imports such as 'io.reactivex.rxjava3.core'
Design

Line: 18

              
import java.util.*;

import io.reactivex.rxjava3.core.*;
import io.reactivex.rxjava3.functions.Consumer;
import io.reactivex.rxjava3.schedulers.Schedulers;

/**
 * Utility for retrieving a mock eventstream for testing.

            

Reported by PMD.