DataGenerator
DataGenerator copied to clipboard
Is there any way to intialize an object in it's constructor?
I've been using DataGenerator to do things like:
var data = DataGenerator.Generator.Default.Single<MyType>();
But sometimes I need to be able to do this:
class MyType
{...}
class MyTypeMocked : MyType
{
void MyTypeMocked()
{
//initialize the class in place here, not via object creation by DataGenerator
}
}
Is there any way to use DataGenerator to update the current object in this way?