Class TestKitSettings
Contains settings to be used when writing tests with TestKit.
public class TestKitSettings : IExtension
- Inheritance
-
TestKitSettings
- Implements
-
IExtension
- Inherited Members
Constructors
TestKitSettings(Config)
Initializes a new instance of the TestKitSettings class.
public TestKitSettings(Config config)
Parameters
config
ConfigThe configuration to use when setting up the tests.
Exceptions
- Akka.Configuration.ConfigurationException
This exception is thrown when a negative value is given for the
akka.test.timefactor
configuration item.
Properties
DefaultTimeout
Gets the default timeout as specified in the setting akka.test.default-timeout. Typically used for Ask-timeouts. It is always finite.
public TimeSpan DefaultTimeout { get; }
Property Value
LogTestKitCalls
If set to true
calls to testkit will be logged.
This is enabled by setting the configuration value "akka.test.testkit.debug" to a true.
public bool LogTestKitCalls { get; }
Property Value
SingleExpectDefault
Gets the config value "akka.test.single-expect-default". It is always finite.
public TimeSpan SingleExpectDefault { get; }
Property Value
TestEventFilterLeeway
Gets the config value "akka.test.filter-leeway". It is always finite.
public TimeSpan TestEventFilterLeeway { get; }
Property Value
TestTimeFactor
Gets the timefactor by which all values are scaled by.
The tight timeouts you use during testing on your lightning-fast notebook will invariably lead to spurious test failures on the heavily loaded CI server. To account for this situation, all maximum durations are internally scaled by this factor, which defaults to 1. To change this value set configuration "akka.test.timefactor" to a positive double/integer.
You can scale other durations with the same factor by using the Testkit.Dilated
public double TestTimeFactor { get; }