@Beta
public interface IMockMakerSettings
IMockMaker
and created explicitly for the requested mock maker.
The user will create such an instance at the mocking site:
Mock(mockMaker: yourMockSettings { yourProperty = true }, ClassToMock)
The IMockMaker
should define a static constant or method (see MockMakers
),
which let the user construct a custom IMockMakerSettings
.
If you provide a method, you can define your settings in a typesafe manner for the user,
e.g. with a Closure
parameter to configure the mock.
Modifier and Type | Method and Description |
---|---|
MockMakerId |
getMockMakerId() |
static IMockMakerSettings |
settingsFor(MockMakerId id)
Creates a default
IMockMakerSettings object with only an MockMakerId . |
static IMockMakerSettings settingsFor(MockMakerId id)
IMockMakerSettings
object with only an MockMakerId
.id
- the mock maker ID.MockMakerId getMockMakerId()