Beispiel #1
0
        public void Setup()
        {
            _relay = new Relay();
            var stubSubscribers = Enumerable.Range(0, 10).Select(_ => new StubSubscriber());

            foreach (var stubSubscriber in stubSubscribers)
            {
                _relay.AddSubscriber(stubSubscriber);
            }
            _message = new Message("benchmark");
        }
 public void Setup()
 {
     _relay = new Relay();
     _relay.AddSubscriber(new StubSubscriber());
     _message = new Message("benchmark");
 }
Beispiel #3
0
 public void AddSubscriber_GivenNull_ThrowsArgumentNullException() => 
     Assert.Throws<ArgumentNullException>(() => _relay.AddSubscriber(null));