Default Greedy constructor behavior breaks filling
description
Hello!
I have a base class for all domain entities called EntityBase, with private GUID id field. If I explicitly define greedy constructor for each entity like that:
Fixture.Customize<User>(c => c.FromFactory( new ConstructorInvoker(new GreedyConstructorQuery() )));
AutoFixture fills every field and ID.. I wanted to make greedy behavior deafult by:
Fixture.Customizations.Add(new ConstructorInvoker( new GreedyConstructorQuery()));
now AutoFixture fills ID properly but all other fields are just null.
Am I missing something ?
thanks!
And also, base class customizations are ignored, is this by design:
Fixture.Customize<EntityBase>(c => c.FromFactory( new ConstructorInvoker(new GreedyConstructorQuery() )));