Package org.instancio.junit
Annotation Type WithSettings
An annotation for supplying custom settings to a unit test.
This annotation must be placed on a Settings fields.
There can be at most one field annotated @WithSettings per test class.
@ExtendWith(InstancioExtension.class)
class ExampleTest {
@WithSettings
private final Settings settings = Settings.create()
.set(Keys.COLLECTION_MIN_SIZE, 50)
.set(Keys.COLLECTION_MAX_SIZE, 100);
}