Пример #1
0
 public void null_describe_source_throws_argument_null_exception()
 {
     var ps = new ProjectionSubscription(
         Guid.NewGuid(), CheckpointTag.FromPosition(0, -1),
         new TestMessageHandler <ProjectionMessage.Projections.CommittedEventReceived>(),
         new TestMessageHandler <ProjectionMessage.Projections.CheckpointSuggested>(), null, 1000);
 }
Пример #2
0
 public void null_ceckpoint_handler_throws_argument_null_exception()
 {
     var ps = new ProjectionSubscription(
         Guid.NewGuid(), CheckpointTag.FromPosition(0, -1),
         new TestMessageHandler <ProjectionMessage.Projections.CommittedEventReceived>(), null,
         CreateCheckpointStrategy(), 1000);
 }
Пример #3
0
 public void it_can_be_created()
 {
     var ps = new ProjectionSubscription(
         Guid.NewGuid(), CheckpointTag.FromPosition(0, -1),
         new TestMessageHandler <ProjectionMessage.Projections.CommittedEventReceived>(),
         new TestMessageHandler <ProjectionMessage.Projections.CheckpointSuggested>(), CreateCheckpointStrategy(),
         1000);
 }
Пример #4
0
 public void null_event_handler_throws_argument_null_exception()
 {
     var ps = new ProjectionSubscription(
         Guid.NewGuid(), CheckpointTag.FromPosition(0, -1), null,
         new TestHandler <ProjectionSubscriptionMessage.CheckpointSuggested>(),
         new TestHandler <ProjectionSubscriptionMessage.ProgressChanged>(), CreateCheckpointStrategy(),
         1000);
 }
        public void setup()
        {
            _checkpointUnhandledBytesThreshold = 1000;
            Given();
            _bus = new FakePublisher();
            _projectionCorrelationId = Guid.NewGuid();
            _eventHandler            = new TestMessageHandler <ProjectionMessage.Projections.CommittedEventReceived>();
            _checkpointHandler       = new TestMessageHandler <ProjectionMessage.Projections.CheckpointSuggested>();
            _subscription            = new ProjectionSubscription(
                _projectionCorrelationId, CheckpointTag.FromPosition(0, -1), _eventHandler, _checkpointHandler,
                CreateCheckpointStrategy(), _checkpointUnhandledBytesThreshold);


            When();
        }
Пример #6
0
 public IDisposable Connect(IObservable <Tin> source)
 {
     this.subscription = new ProjectionSubscription(this, source.Subscribe(this));
     return(this.subscription);
 }