This is driving me crazy:
I have integration tests where I use Data Access Application Block (latest version as of today 5.0.505.0). And I code against it as always:
Database db = EnterpriseLibraryContainer.Current.GetInstance<Database>();
But here it throws exception with this info:
Microsoft.Practices.ServiceLocation.ActivationException: Activation error occured while trying to get instance of type Database, key "" ---> Microsoft.Practices.Unity.ResolutionFailedException: Resolution of the dependency failed, type = "Microsoft.Practices.EnterpriseLibrary.Data.Database",
name = "(none)".
Then in output:
---> System.InvalidOperationException: The type Database does not have an accessible constructor.
What is this???