public class Reporter
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private static java.lang.ThreadLocal<ITestResult> |
m_currentTestResult |
private static boolean |
m_escapeHtml |
private static java.util.Map<java.lang.Integer,java.util.List<java.lang.Integer>> |
m_methodOutputMap
The key is the hashCode of the ITestResult
|
private static java.lang.ThreadLocal<java.util.List<java.lang.String>> |
m_orphanedOutput |
private static java.util.List<java.lang.String> |
m_output
All output logged in a sequential order.
|
Constructor and Description |
---|
Reporter() |
Modifier and Type | Method and Description |
---|---|
static void |
clear()
Erase the content of all the output generated so far.
|
static ITestResult |
getCurrentTestResult() |
static boolean |
getEscapeHtml() |
static java.util.List<java.lang.String> |
getOutput() |
static java.util.List<java.lang.String> |
getOutput(ITestResult tr) |
static void |
log(java.lang.String s)
Log the passed string to the HTML reports
|
static void |
log(java.lang.String s,
boolean logToStandardOut)
Log the passed string to the HTML reports.
|
static void |
log(java.lang.String s,
int level)
Log the passed string to the HTML reports if the current verbosity
is equal or greater than the one passed in parameter
|
static void |
log(java.lang.String s,
int level,
boolean logToStandardOut)
Log the passed string to the HTML reports if the current verbosity
is equal or greater than the one passed in parameter.
|
private static void |
log(java.lang.String s,
ITestResult m) |
static void |
setCurrentTestResult(ITestResult m) |
static void |
setEscapeHtml(boolean escapeHtml) |
private static java.lang.ThreadLocal<ITestResult> m_currentTestResult
private static java.util.List<java.lang.String> m_output
private static java.util.Map<java.lang.Integer,java.util.List<java.lang.Integer>> m_methodOutputMap
private static boolean m_escapeHtml
private static java.lang.ThreadLocal<java.util.List<java.lang.String>> m_orphanedOutput
public static void setCurrentTestResult(ITestResult m)
public static java.util.List<java.lang.String> getOutput()
public static void clear()
public static boolean getEscapeHtml()
public static void setEscapeHtml(boolean escapeHtml)
escapeHtml
- If true, use HTML entities for special HTML characters (<, >, &, ...).private static void log(java.lang.String s, ITestResult m)
public static void log(java.lang.String s)
s
- The message to logpublic static void log(java.lang.String s, int level, boolean logToStandardOut)
s
- The message to loglevel
- The verbosity of this messagelogToStandardOut
- Whether to print this string on standard
out toopublic static void log(java.lang.String s, boolean logToStandardOut)
s
- The message to loglogToStandardOut
- Whether to print this string on standard
out toopublic static void log(java.lang.String s, int level)
s
- The message to loglevel
- The verbosity of this messagepublic static ITestResult getCurrentTestResult()
public static java.util.List<java.lang.String> getOutput(ITestResult tr)