public void SubmitMessageTest()
        {
            using (SyslogTlsReceiver receiver = new SyslogTlsReceiver {
                Port = 7614, Log = new SimpleLogImpl(new NullCollector())
            })
            {
                receiver.MessageReceived += (sender, e) => _messageReceived.Set();
                receiver.Start();
                using (SyslogTlsCollector target = new SyslogTlsCollector
                {
                    Configuration =
                        new Dictionary <string, string> {
                        { "host", "localhost" }, { "port", "7614" }
                    }
                })
                {
                    SyslogMessage message = new SyslogMessage("localhost", SyslogFacility.Local0, SyslogSeverity.Critical,
                                                              "Hello log!");


                    ((ILogCollector)target).SubmitMessage(message);
                    if (!_messageReceived.WaitOne(5000))
                    {
                        Assert.Fail("Waiting too much...");
                    }
                }
            }
        }
        public void GetConfigurationParameterTest()
        {
            SyslogTlsCollector target = new SyslogTlsCollector()
            {
                Configuration = new Dictionary <string, string> {
                    { "host", "myhost.mydomain.com" }
                }
            };                                       // TODO: Eseguire l'inizializzazione a un valore appropriato
            string key      = "host";                // TODO: Eseguire l'inizializzazione a un valore appropriato
            string expected = "myhost.mydomain.com"; // TODO: Eseguire l'inizializzazione a un valore appropriato
            string actual;

            actual = target.GetConfigurationParameter(key);
            Assert.AreEqual(expected, actual);
        }