Ejemplo n.º 1
0
        public virtual void TestInterceptor()
        {
            ILogging logger = Logger.Get(typeof(LoggingTestCase.ITestLogger));

            Logger.Intercept(new _ILoggingInterceptor_136());
            ByRef called = new ByRef();

            logger.Forward(new _ITestLogger_145(called));
            ((LoggingTestCase.ITestLogger)logger.Debug()).Msg();
            Assert.AreEqual(Logger.Debug, ((Level)called.value));
            called.value = null;
            logger       = Logger.Get(typeof(LoggingTestCase.ITestLogger));
            ((LoggingTestCase.ITestLogger)logger.Debug()).Msg();
            Assert.AreEqual(Logger.Debug, ((Level)called.value));
        }