I have two implementation of context providers and I know there will be more to follow.
I would like to create interface to work for those entities in generic.
public class TDataProvider
{
public TEntities GetDataContext()
{
return new TTEntities();
}
}
public class TDataProvider
{
public TEntities GetDataContext()
{
return new TTEntities();
}
}
I want to use the interface that is mplemeneted in each case such as
But how do I implement followin inteface over the entity model generated by ADO.NET Entity Data Model?
public class IGetDataContext
{
T GetDataContext();
}
Instead of creating interface on context I have created data access classes responsible for actions and created unit test against that.
Its the best I could think of.