public void ReceiveMessageBase(MessageBase testMessage)
        {
            Assert.IsNotNull(testMessage);

            var castedMessage = testMessage as ITestMessage;

            if (castedMessage != null)
            {
                Assert.AreEqual(testContent, castedMessage.Content);
                _messageWasReceived = true;
                _messageWasReceivedInMessageBase = true;
            }
        }
 public void ReceiveStringNested(MessageBase m)
 {
     var message = m as GenericMessage<string>;
     if (message != null)
     {
         ReceivedStringMessages++;
         LastReceivedString = message.Content;
     }
 }
 public virtual void ReceiveString(MessageBase m)
 {
     var message = m as GenericMessage<string>;
     if (message != null)
     {
         Messenger.Default.Register<MessageBase>(this, true, ReceiveStringNested);
     }
 }