Esempio n. 1
0

        
Esempio n. 2
0
            public void Should_apply_sent_message_event()
            {
                var @event = _source.Flush().OfType <SentMessageEvent>().Single();

                Assert.AreEqual(_userId, @event.UserId);
                Assert.AreEqual(_messageId, @event.MessageId);
                Assert.AreEqual(_message, @event.Message);
                Assert.IsTrue(@event.Sent > _now);
            }
Esempio n. 3
0
        public T Build()
        {
            _source = _aggregate = _eventSourceFactory.Create <T>();

            _source.Hydrate(_events);
            _source.Flush();

            return(_aggregate);
        }
Esempio n. 4
0
 protected override void Event()
 {
     _flushedEvents = _eventSource.Flush().Cast <IEvent>();
 }