object Tests
- Alphabetic
- By Inheritance
- Tests
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
final
case class
Argument(framework: Option[TestFramework], args: List[String]) extends TestOption with Product with Serializable
Defines arguments to pass to test frameworks.
Defines arguments to pass to test frameworks.
- framework
The test framework the arguments apply to if one is specified in Some. If None, the arguments will apply to all test frameworks.
- args
The list of arguments to pass to the selected framework(s).
-
final
case class
Cleanup(cleanup: (ClassLoader) ⇒ Unit) extends TestOption with Product with Serializable
Defines a TestOption that will evaluate
cleanup
after all tests execute.Defines a TestOption that will evaluate
cleanup
after all tests execute. The ClassLoader provided tocleanup
is the loader containing the test classes that ran. Cleanup is not currently performed for forked tests. -
final
case class
Exclude(tests: Iterable[String]) extends TestOption with Product with Serializable
The names of tests to explicitly exclude from execution.
-
final
case class
Execution(options: Seq[TestOption], parallel: Boolean, tags: Seq[(Tag, Int)]) extends Product with Serializable
Configures test execution.
Configures test execution.
- options
The options to apply to this execution, including test framework arguments, filters, and setup and cleanup work.
- parallel
If true, execute each unit of work returned by the test frameworks in separate sbt.Tasks. If false, execute all work in a single sbt.Task.
- tags
The tags that should be added to each test task. These can be used to apply restrictions on concurrent execution.
-
final
case class
Filter(filterTest: (String) ⇒ Boolean) extends TestOption with Product with Serializable
Selects tests by name to run.
Selects tests by name to run. Only tests for which
filterTest
returns true will be run. -
final
case class
Filters(filterTest: Seq[(String) ⇒ Boolean]) extends TestOption with Product with Serializable
Test execution will be ordered by the position of the matching filter.
-
final
class
Group extends Product with Serializable
A named group of tests configured to run in the same JVM or be forked.
- final case class Listeners(listeners: Iterable[TestReportListener]) extends TestOption with Product with Serializable
-
final
case class
Output(overall: TestResult, events: Map[String, SuiteResult], summaries: Iterable[Summary]) extends Product with Serializable
The result of a test run.
The result of a test run.
- overall
The overall result of execution across all tests for all test frameworks in this test run.
- events
The result of each test group (suite) executed during this test run.
- summaries
Explicit summaries directly provided by test frameworks. This may be empty, in which case a default summary will be generated.
-
final
case class
Setup(setup: (ClassLoader) ⇒ Unit) extends TestOption with Product with Serializable
Defines a TestOption that will evaluate
setup
before any tests execute.Defines a TestOption that will evaluate
setup
before any tests execute. The ClassLoader provided tosetup
is the loader containing the test classes that will be run. Setup is not currently performed for forked tests. -
final
case class
SubProcess(config: ForkOptions) extends TestRunPolicy with Product with Serializable
Configures a group of tests to be forked in a new JVM with forking options specified by
config
. -
final
case class
Summary(name: String, summaryText: String) extends Product with Serializable
Summarizes a test run.
Summarizes a test run.
- name
The name of the test framework providing this summary.
- summaryText
The summary message for tests run by the test framework.
-
sealed
trait
TestRunPolicy extends AnyRef
Configures whether a group of tests runs in the same JVM or are forked.
- type TestRunnable = (String, TestFunction)
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
Argument(tf: TestFramework, args: String*): Argument
Defines a TestOption that passes arguments
args
to only the test frameworktf
. -
def
Argument(args: String*): Argument
Defines a TestOption that passes arguments
args
to all test frameworks. -
def
Cleanup(cleanup: () ⇒ Unit): Cleanup
Defines a TestOption that will evaluate
cleanup
after all tests execute.Defines a TestOption that will evaluate
cleanup
after all tests execute. Cleanup is not currently performed for forked tests. -
def
Setup(setup: () ⇒ Unit): Setup
Defines a TestOption that will evaluate
setup
before any tests execute.Defines a TestOption that will evaluate
setup
before any tests execute. Setup is not currently performed for forked tests. - def allDefs(analysis: CompileAnalysis): Seq[Definition]
- def apply(frameworks: Map[TestFramework, Framework], testLoader: ClassLoader, runners: Map[TestFramework, Runner], discovered: Vector[TestDefinition], config: Execution, log: ManagedLogger): Task[Output]
- def apply(frameworks: Map[TestFramework, Framework], testLoader: ClassLoader, runners: Map[TestFramework, Runner], o: ProcessedOptions, config: Execution, log: ManagedLogger): Task[Output]
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- def discover(fingerprints: Seq[Fingerprint], definitions: Seq[Definition], log: Logger): (Seq[TestDefinition], Set[String])
- def discover(frameworks: Seq[Framework], analysis: CompileAnalysis, log: Logger): (Seq[TestDefinition], Set[String])
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
- def foldTasks(results: Seq[Task[Output]], parallel: Boolean): Task[Output]
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def makeParallel(loader: ClassLoader, runnables: Iterable[TestRunnable], setupTasks: Task[Unit], tags: Seq[(Tag, Int)]): Task[Map[String, SuiteResult]]
- def makeSerial(loader: ClassLoader, runnables: Seq[TestRunnable], setupTasks: Task[Unit]): Task[List[(String, SuiteResult)]]
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def overall(results: Iterable[TestResult]): TestResult
- def processResults(results: Iterable[(String, SuiteResult)]): Output
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- def testTask(loader: ClassLoader, frameworks: Map[TestFramework, Framework], runners: Map[TestFramework, Runner], tests: Vector[TestDefinition], userSetup: Iterable[(ClassLoader) ⇒ Unit], userCleanup: Iterable[(ClassLoader) ⇒ Unit], log: ManagedLogger, testListeners: Vector[TestReportListener], config: Execution): Task[Output]
-
def
toString(): String
- Definition Classes
- AnyRef → Any
- def toTask(loader: ClassLoader, name: String, fun: TestFunction, tags: Seq[(Tag, Int)]): Task[Map[String, SuiteResult]]
- def toTasks(loader: ClassLoader, runnables: Seq[TestRunnable], tags: Seq[(Tag, Int)]): Task[Map[String, SuiteResult]]
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- object Group extends AbstractFunction3[String, Seq[TestDefinition], TestRunPolicy, Group] with Serializable
-
object
InProcess extends TestRunPolicy with Product with Serializable
Configures a group of tests to run in the same JVM.
Deprecated Value Members
-
def
makeSerial(loader: ClassLoader, runnables: Seq[TestRunnable], setupTasks: Task[Unit], tags: Seq[(Tag, Int)]): Task[List[(String, SuiteResult)]]
- Annotations
- @deprecated
- Deprecated
(Since version 1.1.1) Use the variant without tags