Beispiel #1
0
            /*************************************************************************/
            internal TestAppContext(List <string> errors) : base(true, false)
            {
                var log = new ApplicationLog();

                log.Register(new TestLog(errors));

                this.Log = log;
            }
Beispiel #2
0
        public void Mondo_Common_ApplicationLog_WriteError()
        {
            List <string>  errors = new List <string>();
            ApplicationLog log    = new ApplicationLog();

            log.Register(new TestLog(errors));

            log.WriteError(new Exception("Bob's hair is on fire"));

            Assert.AreEqual(1, errors.Count);
            Assert.AreEqual("Bob's hair is on fire", errors[0]);
        }