Class MavenRunListener


  • @ThreadSafe
    public class MavenRunListener
    extends org.junit.runner.notification.RunListener
    Helper class to identify the test being run by maven surefire in the log output. This is particularly useful if there is a lot of "chatty" testing going on.

    See: Using Custom Listeners and Reporters

    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.junit.runner.notification.RunListener

        org.junit.runner.notification.RunListener.ThreadSafe
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void testAssumptionFailure​(org.junit.runner.notification.Failure failure)  
      void testFailure​(org.junit.runner.notification.Failure failure)  
      void testFinished​(org.junit.runner.Description description)  
      void testIgnored​(org.junit.runner.Description description)  
      void testStarted​(org.junit.runner.Description description)  
      • Methods inherited from class org.junit.runner.notification.RunListener

        testRunFinished, testRunStarted, testSuiteFinished, testSuiteStarted
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MavenRunListener

        public MavenRunListener()
    • Method Detail

      • testStarted

        public void testStarted​(org.junit.runner.Description description)
                         throws java.lang.Exception
        Overrides:
        testStarted in class org.junit.runner.notification.RunListener
        Throws:
        java.lang.Exception
      • testFailure

        public void testFailure​(org.junit.runner.notification.Failure failure)
                         throws java.lang.Exception
        Overrides:
        testFailure in class org.junit.runner.notification.RunListener
        Throws:
        java.lang.Exception
      • testAssumptionFailure

        public void testAssumptionFailure​(org.junit.runner.notification.Failure failure)
        Overrides:
        testAssumptionFailure in class org.junit.runner.notification.RunListener
      • testIgnored

        public void testIgnored​(org.junit.runner.Description description)
                         throws java.lang.Exception
        Overrides:
        testIgnored in class org.junit.runner.notification.RunListener
        Throws:
        java.lang.Exception
      • testFinished

        public void testFinished​(org.junit.runner.Description description)
                          throws java.lang.Exception
        Overrides:
        testFinished in class org.junit.runner.notification.RunListener
        Throws:
        java.lang.Exception