This project has moved and is read-only. For the latest updates, please go here.

No Implicit reference Conversion

Mar 12, 2014 at 7:23 AM
I get the following error during building.

DLCPMEntities is of type DBContext so I'm not sure why this doesn't work. I followed the instructions, but I can't even build my unit test. Any help is appreciated.


Error 1 The type 'SunOffice_Core.DLCPMEntities' cannot be used as type parameter 'T' in the generic type or method 'Effort.ObjectContextFactory.CreateTransient<T>()'. There is no implicit reference conversion from 'SunOffice_Core.DLCPMEntities' to 'System.Data.Entity.Core.Objects.ObjectContext'
Mar 15, 2014 at 3:18 PM
Hello,

ObjectContextFactory is not meant to be use with DbContext objects. The following tutorial might help you:
https://effort.codeplex.com/wikipage?title=Create%20a%20fake%20DbContext%20instance&referringTitle=Tutorials