Esempio n. 1
0
        public void listen_by_exact_type()
        {
            var listener = new DebugListener(Level.InfoOnly);
            listener.ListenFor<Log1>();

            listener.ListensFor(typeof(Log1)).ShouldBeTrue();
            listener.ListensFor(typeof(Log2)).ShouldBeFalse();
        }
Esempio n. 2
0
        public void listen_by_exact_type()
        {
            var listener = new DebugListener(Level.InfoOnly);

            listener.ListenFor <Log1>();

            listener.ListensFor(typeof(Log1)).ShouldBeTrue();
            listener.ListensFor(typeof(Log2)).ShouldBeFalse();
        }
Esempio n. 3
0
        public void listens_for_with_multiple_matches()
        {
            var listener = new DebugListener(Level.InfoOnly);
            listener.ListenFor<Log1>().ListenFor<Log2>();

            listener.ListensFor(typeof(Log1)).ShouldBeTrue();
            listener.ListensFor(typeof(Log2)).ShouldBeTrue();
            listener.ListensFor(typeof(Log3)).ShouldBeFalse();
        }
Esempio n. 4
0
        public void listens_for_with_multiple_matches()
        {
            var listener = new DebugListener(Level.InfoOnly);

            listener.ListenFor <Log1>().ListenFor <Log2>();

            listener.ListensFor(typeof(Log1)).ShouldBeTrue();
            listener.ListensFor(typeof(Log2)).ShouldBeTrue();
            listener.ListensFor(typeof(Log3)).ShouldBeFalse();
        }