vertx / io.vertx.ext.unit / TestOptions

# TestOptions

`open class TestOptions : ReportingOptions`

Test execution options:

- the `timeout` in milliseconds, the default value is 2 minutes
- the `useEventLoop`
configures the event loop usage

- `true` always runs with an event loop
- `false` never runs with an event loop
- `null` uses an event loop if there is one (provided by `io.vertx.core.Vertx#currentContext()`) otherwise run without

- the `reporters` is an array of reporter configurations

Author
Julien Viet

### Constructors

<init> | `TestOptions()` Create a new empty options, with the default time out and no reporters. `TestOptions(other: TestOptions)` Copy constructor. `TestOptions(json: JsonObject)` Create a new options from the specified json.

### Properties

DEFAULT_TIMEOUT | `static val DEFAULT_TIMEOUT: Long` The default time out value in milliseconds: 2 minutes.
DEFAULT_USE_EVENT_LOOP | `static val DEFAULT_USE_EVENT_LOOP: Boolean` The default value for using or not the event loop: `null`.

### Functions

addReporter | `open fun addReporter(reportOptions: ReportOptions): TestOptions`
getTimeout | `open fun getTimeout(): Long`
isUseEventLoop | `open fun isUseEventLoop(): Boolean`
setReporters | `open fun setReporters(reporters: MutableList<ReportOptions>): TestOptions`
setTimeout | `open fun setTimeout(timeout: Long): TestOptions` Set the test timeout.
setUseEventLoop | `open fun setUseEventLoop(useEventLoop: Boolean): TestOptions` Configure the execution to use an event loop when there is no one existing.
toJson | `open fun toJson(): JsonObject`

### Inherited Functions

getReporters | `open fun getReporters(): MutableList<ReportOptions>`