Liferay 7.0-ce-b4

com.liferay.portal.test.rule.callback
Class LogAssertionTestCallback

java.lang.Object
  extended by com.liferay.portal.test.rule.callback.LogAssertionTestCallback
All Implemented Interfaces:
TestCallback<List<CaptureAppender>,List<CaptureAppender>>

public class LogAssertionTestCallback
extends Object
implements TestCallback<List<CaptureAppender>,List<CaptureAppender>>


Field Summary
static LogAssertionTestCallback INSTANCE
           
 
Method Summary
 void afterClass(org.junit.runner.Description description, List<CaptureAppender> captureAppenders)
           
 void afterMethod(org.junit.runner.Description description, List<CaptureAppender> captureAppenders, Object target)
           
 List<CaptureAppender> beforeClass(org.junit.runner.Description description)
           
 List<CaptureAppender> beforeMethod(org.junit.runner.Description description, Object target)
           
static void caughtFailure(Error error)
           
static void endAssert(List<ExpectedLogs> expectedLogsList, List<CaptureAppender> captureAppenders)
           
protected static void installJdk14Handler()
           
protected static void installLog4jAppender()
           
protected static boolean isExpected(List<ExpectedLogs> expectedLogsList, String renderedMessage)
           
static List<CaptureAppender> startAssert(List<ExpectedLogs> expectedLogsList)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTANCE

public static final LogAssertionTestCallback INSTANCE
Method Detail

caughtFailure

public static void caughtFailure(Error error)

endAssert

public static void endAssert(List<ExpectedLogs> expectedLogsList,
                             List<CaptureAppender> captureAppenders)

startAssert

public static List<CaptureAppender> startAssert(List<ExpectedLogs> expectedLogsList)

afterClass

public void afterClass(org.junit.runner.Description description,
                       List<CaptureAppender> captureAppenders)
Specified by:
afterClass in interface TestCallback<List<CaptureAppender>,List<CaptureAppender>>

afterMethod

public void afterMethod(org.junit.runner.Description description,
                        List<CaptureAppender> captureAppenders,
                        Object target)
Specified by:
afterMethod in interface TestCallback<List<CaptureAppender>,List<CaptureAppender>>

beforeClass

public List<CaptureAppender> beforeClass(org.junit.runner.Description description)
Specified by:
beforeClass in interface TestCallback<List<CaptureAppender>,List<CaptureAppender>>

beforeMethod

public List<CaptureAppender> beforeMethod(org.junit.runner.Description description,
                                          Object target)
Specified by:
beforeMethod in interface TestCallback<List<CaptureAppender>,List<CaptureAppender>>

installJdk14Handler

protected static void installJdk14Handler()

installLog4jAppender

protected static void installLog4jAppender()

isExpected

protected static boolean isExpected(List<ExpectedLogs> expectedLogsList,
                                    String renderedMessage)

Liferay 7.0-ce-b4