Example #1
0
        public void unsubscribed_messages_noone_should_handle_it()
        {
            var handler1 = new TestHandler();
            var handler2 = new TestHandler2();
            var handler3 = new TestHandler3();

            Bus.Publish(new TestMessage());
            Bus.Publish(new TestMessage2());
            Bus.Publish(new TestMessage3());

            Assert.That(handler1.DidntHandleAnyMessages() &&
                        handler2.DidntHandleAnyMessages() &&
                        handler3.DidntHandleAnyMessages());
        }
Example #2
0
        public void unsubscribed_messages_noone_should_handle_it()
        {
            var handler1 = new TestHandler();
            var handler2 = new TestHandler2();
            var handler3 = new TestHandler3();

            Bus.Publish(new TestMessage());
            Bus.Publish(new TestMessage2());
            Bus.Publish(new TestMessage3());

            Assert.That(handler1.DidntHandleAnyMessages() &&
                        handler2.DidntHandleAnyMessages() &&
                        handler3.DidntHandleAnyMessages());
        }