public void When_InValidHeartbeatMessageDeviceNumberContainsCharacters_ThenMessagedetailsAreNotPublished() { _count = 0; HeartbeatProcessor processor = new HeartbeatProcessor(); _container.ComposeParts(processor); IMessage message = new Message(processor.MessageType, "A:10"); processor.Execute(message); Assert.AreEqual(0, _count, "The message fired and it should not have"); }
public void When_InValidHeartbeatMessageArrives_ThenMessagedetailsAreNotPublished() { _count = 0; HeartbeatProcessor processor = new HeartbeatProcessor(); _container.ComposeParts(processor); IMessage message = new Message("BLAH", "1:10"); processor.Execute(message); Assert.AreEqual(0, _count, "The message fired and it should not have"); }
public void When_ValidHeartbeatMessageArrives_ThenMessagedetailsArePublished() { _count = 0; HeartbeatProcessor processor = new HeartbeatProcessor(); _container.ComposeParts(processor); IMessage message = new Message(processor.MessageType,"1:10"); processor.Execute(message); Assert.AreEqual(1,_count,"The message did not fire"); }