Package org.jboss.logging

Examples of org.jboss.logging.Logger


   {
      synchronized (stateLock)
      {
         if (destroyed)
         {
            Logger log = getLog();
            if (log.isTraceEnabled())
               log.trace("Not broadcasting error, already destroyed " + this, e);
            return;
         }
      }

      Exception ex = null;
View Full Code Here


        verify(mock);
    }

    @Test
    public void testInfoWithException() {
        Logger mock =
            createStrictMock(Logger.class);

        mock.info("a", e);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        logger.info("a", e);
        verify(mock);
View Full Code Here

        verify(mock);
    }

    @Test
    public void testWarn() {
        Logger mock =
            createStrictMock(Logger.class);

        mock.warn("a");
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        logger.warn("a");
        verify(mock);
View Full Code Here

        verify(mock);
    }

    @Test
    public void testWarnWithException() {
        Logger mock =
            createStrictMock(Logger.class);

        mock.warn("a", e);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        logger.warn("a", e);
        verify(mock);
View Full Code Here

        verify(mock);
    }

    @Test
    public void testError() {
        Logger mock =
            createStrictMock(Logger.class);

        mock.error("a");
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        logger.error("a");
        verify(mock);
View Full Code Here

        verify(mock);
    }

    @Test
    public void testErrorWithException() {
        Logger mock =
            createStrictMock(Logger.class);

        mock.error("a", e);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        logger.error("a", e);
        verify(mock);
View Full Code Here

    private static final Exception e = new Exception();

    @Test
    @SuppressWarnings("deprecation")
    public void testIsDebugEnabled() {
        Logger mock =
            createStrictMock(Logger.class);

        expect(mock.isDebugEnabled()).andReturn(true);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        assertTrue(logger.isDebugEnabled());
        verify(mock);
View Full Code Here

    }

    @Test
    @SuppressWarnings("deprecation")
    public void testIsInfoEnabled() {
        Logger mock =
            createStrictMock(Logger.class);

        expect(mock.isInfoEnabled()).andReturn(true);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        assertTrue(logger.isInfoEnabled());
        verify(mock);
View Full Code Here

        verify(mock);
    }

    @Test
    public void testIsWarnEnabled() {
        Logger mock =
            createStrictMock(Logger.class);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        assertTrue(logger.isWarnEnabled());
View Full Code Here

        verify(mock);
    }

    @Test
    public void testIsErrorEnabled() {
        Logger mock =
            createStrictMock(Logger.class);
        replay(mock);

        InternalLogger logger = new JBossLogger(mock);
        assertTrue(logger.isErrorEnabled());
View Full Code Here

TOP

Related Classes of org.jboss.logging.Logger

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.