MisterJames / GenFu

GenFu is a library you can use to generate realistic test data. It is composed of several property fillers that can populate commonly named properties through reflection using an internal database of values or randomly created data. You can override any of the fillers, give GenFu hints on how to fill them.
Other
831 stars 100 forks source link

Create static data #140

Open mdarefull opened 6 years ago

mdarefull commented 6 years ago

One of the pain of unit testing is the need to build fake data (entities, dtos) to be passed to the SUT. One of the requirements of a unit test is that it should be repeatable, so we cannot generate different input on each test execution.

IMO, it will be great if there is some addition to the library to make (at least) its ListOf a pure function: It should generate exactly the same set of data on each execution, perhaps based on a seed parameter, much like pseudo random number generators work.