Commit Graph

4 Commits

Author SHA1 Message Date
Shannon Deminick
a0e4492a35 New implementation of IDatabaseFactory, allows setting the DatabaseContext.Current at runtime
with a custom IDatabaseFactory (mostly for testing).
Changes AuditTrail to internal so the public way is just with the 'Audit' class.
Fixed ThreadSafetyServiceTests which was failing with the new AuditTrail stuff because of the
Database instances, this is not solved with the new PerThreadDatabaseFactory for the unit test.
Created new 'UmbracoDatabase' object which inherits from the PetaPoco one so that we can future proof
the implementation as we might want some custom logic on there. Now the IDatabaseFactory returns
an UmbracoDatabase instead of just Database.
2012-12-12 03:47:04 +05:00
Shannon Deminick
6ac2db9497 removed database factory, changed audit trail stuff to internal, not sure it needs to be public. 2012-12-12 00:17:59 +05:00
Shannon Deminick
cfa8fc2bba Removed the uow ctor from the SaveEventArgs for testing as the test will still prove that
multi-threading works with the services without proving access to a single uow, the db will error first anyways.
2012-12-11 22:56:34 +05:00
Shannon Deminick
feff68ada8 Refactor new Services for thread safety, plus unit tests. Not all services are updated to be correct, only the
ContentService, the rest need to be updated as well.
2012-12-11 12:03:36 +05:00