public void MessageSourceWithRealTarget_Struct()
        {
            // Prepare
            var dummyMessenger = new FirLibMessenger();

            dummyMessenger.ConnectToGlobalMessaging(
                FirLibMessengerThreadingBehavior.Ignore,
                "DummyMessenger",
                null);
            try
            {
                var realHandlerCalled = false;
                dummyMessenger.Subscribe <TestMessageStruct>(_ => realHandlerCalled = true);

                // Execute test
                var messageSource = new FirLibMessageSource <TestMessageStruct>("DummyMessenger");
                messageSource.Publish(new TestMessageStruct("Testing argument"));

                // Check results
                Assert.IsTrue(realHandlerCalled);
            }
            finally
            {
                // Cleanup
                dummyMessenger.DisconnectFromGlobalMessaging();
            }
        }
        public void MessageSourceWithCustomTarget_Struct()
        {
            // Prepare
            var customHandlerCalled = false;
            var messageSource       = new FirLibMessageSource <TestMessageStruct>(FirLibConstants.MESSENGER_NAME_GUI);

            messageSource.UnitTesting_ReplaceByCustomMessageTarget(
                _ => customHandlerCalled = true);

            // Execute test
            messageSource.Publish(new TestMessageStruct("Testing argument"));

            // Check results
            Assert.IsTrue(customHandlerCalled);
        }