Пример #1
0
        public void it_should_tell_itself_to_end_the_session()
        {
            var sut = new StandInInternalSession();

            sut.Dispose();

            sut.EndWasCalled.ShouldBeTrue();
        }
        public void it_should_not_call_enroll()
        {
            var sut = new StandInInternalSession(null, null);

            var mockRegisteredGraph = MockRepository.GenerateStub<IRegisteredGraph<DummyPersistentObject>>();
            var mockStoredGraph = MockRepository.GenerateStub<IStoredGraph>();

            mockStoredGraph.SerialisedGraph = new PreservedMemoryStream(new byte[0]);

            sut.Load(mockStoredGraph, mockRegisteredGraph, null, true);

            sut.Called.ShouldBeFalse();
        }