public void Should_Not_Throw_Exception_If_Complete_Called() { using (var uow = new InnerUnitOfWorkCompleteHandle()) { uow.Complete(); } }
public void ShouldNotThrowExceptionIfCompleteCalled() { using (var uow = new InnerUnitOfWorkCompleteHandle()) { uow.Complete(); } }
public void Should_Throw_Exception_If_Complete_Did_Not_Called() { Assert.Throws <AbpException>(() => { using (var uow = new InnerUnitOfWorkCompleteHandle()) { } }).Message.ShouldBe(InnerUnitOfWorkCompleteHandle.DidNotCallCompleteMethodExceptionMessage); }
public void ShouldThrowExceptionIfCompleteDidNotCalled() { Assert.Throws <StudioXException>(() => { using (var uow = new InnerUnitOfWorkCompleteHandle()) { } }).Message.ShouldBe(InnerUnitOfWorkCompleteHandle.DidNotCallCompleteMethodExceptionMessage); }
public void Should_Not_Override_Exception_If_Exception_Is_Thrown_By_User() { Assert.Throws <Exception>( new Action(() => { using (var uow = new InnerUnitOfWorkCompleteHandle()) { throw new Exception("My inner exception!"); } })).Message.ShouldBe("My inner exception!"); }
public void ShouldNotOverrideExceptionIfExceptionIsThrownByUser() { Assert.Throws <Exception>( new Action(() => { using (var uow = new InnerUnitOfWorkCompleteHandle()) { throw new Exception("My inner exception!"); } })).Message.ShouldBe("My inner exception!"); }