Class AsyncTestRunner

java.lang.Object
org.junit.runner.Runner
org.junit.runners.ParentRunner<org.junit.runners.model.FrameworkMethod>
org.junit.runners.BlockJUnit4ClassRunner
com.google.j2cl.junit.async.AsyncTestRunner
All Implemented Interfaces:
org.junit.runner.Describable, org.junit.runner.manipulation.Filterable, org.junit.runner.manipulation.Orderable, org.junit.runner.manipulation.Sortable

public class AsyncTestRunner extends org.junit.runners.BlockJUnit4ClassRunner
A test runner that allows for asynchronous test using LitenableFuture or a structural Promise.

See PROMISE_LIKE for the expected requirements of structural promise. Note that this mimics the J2CL version the type but has less requirements since they don't make sense for the JVM version of the promise-like object.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected org.junit.runners.model.Statement
    methodInvoker(org.junit.runners.model.FrameworkMethod method, Object test)
     
    protected void
    validatePublicVoidNoArgMethods(Class<? extends Annotation> annotation, boolean isStatic, List<Throwable> errors)
     
    protected org.junit.runners.model.Statement
    withAfters(org.junit.runners.model.FrameworkMethod method, Object target, org.junit.runners.model.Statement next)
     
    protected org.junit.runners.model.Statement
    withBefores(org.junit.runners.model.FrameworkMethod method, Object target, org.junit.runners.model.Statement next)
     
    protected org.junit.runners.model.Statement
    withPotentialTimeout(org.junit.runners.model.FrameworkMethod method, Object test, org.junit.runners.model.Statement next)
     

    Methods inherited from class org.junit.runners.BlockJUnit4ClassRunner

    collectInitializationErrors, computeTestMethods, createTest, createTest, describeChild, getChildren, getTestRules, isIgnored, methodBlock, possiblyExpectingExceptions, rules, runChild, testName, validateConstructor, validateFields, validateInstanceMethods, validateNoNonStaticInnerClass, validateOnlyOneConstructor, validateTestMethods, validateZeroArgConstructor

    Methods inherited from class org.junit.runners.ParentRunner

    childrenInvoker, classBlock, classRules, createTestClass, filter, getDescription, getName, getRunnerAnnotations, getTestClass, order, run, runLeaf, setScheduler, sort, withAfterClasses, withBeforeClasses, withInterruptIsolation

    Methods inherited from class org.junit.runner.Runner

    testCount

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • AsyncTestRunner

      public AsyncTestRunner(Class<?> klass) throws org.junit.runners.model.InitializationError
      Throws:
      org.junit.runners.model.InitializationError
  • Method Details

    • methodInvoker

      protected org.junit.runners.model.Statement methodInvoker(org.junit.runners.model.FrameworkMethod method, Object test)
      Overrides:
      methodInvoker in class org.junit.runners.BlockJUnit4ClassRunner
    • withPotentialTimeout

      protected org.junit.runners.model.Statement withPotentialTimeout(org.junit.runners.model.FrameworkMethod method, Object test, org.junit.runners.model.Statement next)
      Overrides:
      withPotentialTimeout in class org.junit.runners.BlockJUnit4ClassRunner
    • withBefores

      protected org.junit.runners.model.Statement withBefores(org.junit.runners.model.FrameworkMethod method, Object target, org.junit.runners.model.Statement next)
      Overrides:
      withBefores in class org.junit.runners.BlockJUnit4ClassRunner
    • withAfters

      protected org.junit.runners.model.Statement withAfters(org.junit.runners.model.FrameworkMethod method, Object target, org.junit.runners.model.Statement next)
      Overrides:
      withAfters in class org.junit.runners.BlockJUnit4ClassRunner
    • validatePublicVoidNoArgMethods

      protected void validatePublicVoidNoArgMethods(Class<? extends Annotation> annotation, boolean isStatic, List<Throwable> errors)
      Overrides:
      validatePublicVoidNoArgMethods in class org.junit.runners.ParentRunner<org.junit.runners.model.FrameworkMethod>