Refactoring ITransactionManager to remove usage of TransationScope

Adds a new RequireNew() method to start a new transactions.

--HG--
branch : 1.x
This commit is contained in:
Sebastien Ros
2013-02-25 15:10:50 -08:00
parent da6fd5fac6
commit c5aa1382e7
6 changed files with 99 additions and 95 deletions

View File

@@ -27,6 +27,7 @@ using Orchard.Messaging.Services;
using Orchard.Security;
using Orchard.Security.Permissions;
using Orchard.Security.Providers;
using Orchard.Tests.ContentManagement;
using Orchard.Tests.Stubs;
using Orchard.UI.Notify;
using Orchard.Users.Controllers;
@@ -65,7 +66,8 @@ namespace Orchard.Tests.Modules.Users.Controllers {
builder.RegisterType<UserService>().As<IUserService>();
builder.RegisterType<UserPartHandler>().As<IContentHandler>();
builder.RegisterType<OrchardServices>().As<IOrchardServices>();
builder.RegisterType<TransactionManager>().As<ITransactionManager>();
builder.RegisterInstance(new DefaultContentManagerTests.TestSessionLocator(_session)).As<ITransactionManager>();
builder.RegisterType<DefaultShapeTableManager>().As<IShapeTableManager>();
builder.RegisterType<DefaultShapeFactory>().As<IShapeFactory>();
builder.RegisterType<StubExtensionManager>().As<IExtensionManager>();