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

How to fill the Nullable<enum> properties? #170

Open hueifeng opened 2 years ago

hueifeng commented 2 years ago

image

var list = GenFu.GenFu.ListOf<Model>(100);
   public class Model
    {
        public OrderType? TestNullable { get; set; }
        public OrderType Test1 { get; set; }
    }
    public enum OrderType
    {
        Normal = 1
    }