Use three-tier architecture + EF add unit tests

It throws up when running tests:

"System.InvalidOperationException" type of abnormality occurs in mscorlib.dll, but processed in user code

The Entity Framework provider type 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer' registered in the application config file for the ADO.NET provider with invariant name 'System.Data.SqlClient' could not be loaded. Make sure that the assembly-qualified name is used and that the assembly is available to the running application. See http://go.microsoft.com/fwlink/?LinkId=260882 for more information.

After a series of Baidu Finally, see this blog https://blog.csdn.net/haipurui0001/article/details/79355160 sentence, try a little, but still a success

But since I heard plum flower, only these four were cited into (four dll can be found in the packages of the current project)

 

 After the introduction of these dll, test again a success, do some notes

 

 

 

 

Guess you like

Origin www.cnblogs.com/licm/p/11801496.html
Recommended