public void CanGetCorrectNestedCurrentScope() { using (var level1 = new TestUnitOfWork()) { Assert.AreEqual(level1, UnitOfWorkBase.CurrentScope()); using (var level2 = new TestUnitOfWork()) { Assert.AreEqual(level2, UnitOfWorkBase.CurrentScope()); using (var level3 = new TestUnitOfWork()) { Assert.AreEqual(level3, UnitOfWorkBase.CurrentScope()); } Assert.AreEqual(level2, UnitOfWorkBase.CurrentScope()); } Assert.AreEqual(level1, UnitOfWorkBase.CurrentScope()); } }
public virtual void Execute() { Execute(UnitOfWorkBase.CurrentScope()); }