AutoBogus icon indicating copy to clipboard operation
AutoBogus copied to clipboard

Feature: add option to only populate simple types

Open ArnaudB88 opened this issue 2 years ago • 0 comments

I want to request this feature because in our projects we don't want complex type members to be populated. This is the default from the nBuilder github repo from which we are migrating. For faking entity framework entities, we want to manually construct the navigation properties, which are complex types.

This option would allow to specify if only simple type members should be populated like:

        var instance = AutoFaker.Generate<Order>(builder =>
        {
          builder
            .WithOnlySimpleTypes(true);
        });

I will create a PR for this.

ArnaudB88 avatar Nov 03 '22 13:11 ArnaudB88