Uses https://github.com/datafaker-net/datafaker to generate random, fake data for using in WireMock responses.
For Maven users:
<dependency>
<groupId>org.wiremock</groupId>
<artifactId>wiremock-faker-extension</artifactId>
<version>0.1.0</version>
</dependency>
For Gradle users:
dependencies {
implementation 'org.wiremock:wiremock-faker-extension:0.1.0'
}
Then, register this extension as you would any other:
new WireMockServer(wireMockConfig().extensions(RandomExtension.class));
{{ random 'Name.first_name' }}
This will generate random first names in the en-US
locale for every request.