Class SerenityParameterizedRunner

java.lang.Object
org.junit.runner.Runner
org.junit.runners.ParentRunner<org.junit.runner.Runner>
org.junit.runners.Suite
net.serenitybdd.junit.runners.SerenityParameterizedRunner
All Implemented Interfaces:
net.thucydides.model.tags.Taggable, org.junit.runner.Describable, org.junit.runner.manipulation.Filterable, org.junit.runner.manipulation.Orderable, org.junit.runner.manipulation.Sortable

public class SerenityParameterizedRunner extends org.junit.runners.Suite implements net.thucydides.model.tags.Taggable
Run a Serenity test suite using a set of data. Similar to the JUnit parameterized tests, but better ;-).
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.junit.runners.Suite

    org.junit.runners.Suite.SuiteClasses
  • Constructor Summary

    Constructors
    Constructor
    Description
    Only called reflectively.
    SerenityParameterizedRunner(Class<?> klass, net.thucydides.core.webdriver.DriverConfiguration configuration, net.thucydides.core.webdriver.WebDriverFactory webDriverFactory, net.thucydides.model.batches.BatchManager batchManager)
    Test runner used for testing purposes.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    protected List<org.junit.runner.Runner>
     
    List<org.junit.runner.Runner>
     
    int
     
    void
    run(org.junit.runner.notification.RunNotifier notifier)
     
    boolean
     
    void
    subscribeReporter(net.thucydides.model.reports.AcceptanceTestReporter reporter)
     

    Methods inherited from class org.junit.runners.Suite

    describeChild, emptySuite, runChild

    Methods inherited from class org.junit.runners.ParentRunner

    childrenInvoker, classBlock, classRules, collectInitializationErrors, createTestClass, filter, getDescription, getName, getRunnerAnnotations, getTestClass, isIgnored, order, runLeaf, setScheduler, sort, validatePublicVoidNoArgMethods, 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

    • SerenityParameterizedRunner

      public SerenityParameterizedRunner(Class<?> klass, net.thucydides.core.webdriver.DriverConfiguration configuration, net.thucydides.core.webdriver.WebDriverFactory webDriverFactory, net.thucydides.model.batches.BatchManager batchManager) throws Throwable
      Test runner used for testing purposes.
      Parameters:
      klass - The test class to run
      configuration - current system configuration (usually mocked)
      webDriverFactory - a webdriver factory (can be mocked)
      batchManager - a batch manager to process batched testing
      Throws:
      Throwable - - cause anything can happen!
    • SerenityParameterizedRunner

      public SerenityParameterizedRunner(Class<?> klass) throws Throwable
      Only called reflectively. Do not use programmatically.
      Parameters:
      klass - The test class to run
      Throws:
      Throwable - Cause shit happens
  • Method Details

    • runTestsInParallelFor

      public boolean runTestsInParallelFor(Class<?> klass)
    • getThreadCountFor

      public int getThreadCountFor(Class<?> klass)
    • getChildren

      protected List<org.junit.runner.Runner> getChildren()
      Overrides:
      getChildren in class org.junit.runners.Suite
    • run

      public void run(org.junit.runner.notification.RunNotifier notifier)
      Overrides:
      run in class org.junit.runners.ParentRunner<org.junit.runner.Runner>
    • generateReports

      public void generateReports()
    • subscribeReporter

      public void subscribeReporter(net.thucydides.model.reports.AcceptanceTestReporter reporter)
    • getRunners

      public List<org.junit.runner.Runner> getRunners()