public final class TestBuilder
extends java.lang.Object
Test instances.| Constructor and Description |
|---|
TestBuilder() |
| Modifier and Type | Method and Description |
|---|---|
Test |
build()
Constructs a
Test using the values set on this builder. |
TestBuilder |
setBehaviour(Behaviour behaviour)
Sets the behaviour, which controls how the test behaves.
|
TestBuilder |
setDescription(java.lang.String description)
Sets the description of the test.
|
TestBuilder |
setFunction(java.util.Optional<TestFunction> function)
Sets the body of the test.
|
TestBuilder |
setOptions(Options options)
Sets the options applied to the test.
|
TestBuilder |
setTestClass(java.lang.Class<?> testClass)
Sets the class that the test was defined in.
|
public TestBuilder setBehaviour(Behaviour behaviour)
behaviour - The behaviour.TestBuilder.public TestBuilder setTestClass(java.lang.Class<?> testClass)
testClass - The class.TestBuilder.public TestBuilder setDescription(java.lang.String description)
description - The description.TestBuilder.public TestBuilder setFunction(java.util.Optional<TestFunction> function)
Optional is empty the test is classified as pending.function - The function.TestBuilder.public TestBuilder setOptions(Options options)
options - The options.TestBuilder.