Skip to content

3.x: Have all unit tests extend a base test class #6583

Closed
@akarnokd

Description

@akarnokd

By adding a common base class, we can enable a "global" timeout and a per-class log output that prevents Travis CI to stop the build and also not flood the log with all methods:

package io.reactivex.testsupport;

public abstract class RxJavaTest {
  @Rule
  protected Timeout globalTimeout = new Timeout(5, TimeUnit.MINUTES);

  @Test
  @Ignore
  public final void announce() {
  }
}

This way, we no longer have to rely on the random ignores scattered along the codebase. This baseclass-ignore may seem unnecessarily complicated, but unfortunately, I was unable to create a working setting via Gradle's test runner.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions