Class DockerClassRule<T extends DockerContainer>

  • All Implemented Interfaces:
    org.junit.rules.TestRule

    public class DockerClassRule<T extends DockerContainer>
    extends Object
    implements org.junit.rules.TestRule
    Builds a Docker image before running tests, then starts containers on demand. Use with ClassRule. Compared to DockerRule this interacts better with Timeout, including rules like JenkinsRule which run that implicitly: you do not want the timeout applied to a potentially lengthy docker-build command.