org.tap4j.ext.testng
Class TestNGYAMLishUtils

Package class diagram package TestNGYAMLishUtils
java.lang.Object
  extended by org.tap4j.ext.testng.TestNGYAMLishUtils

public final class TestNGYAMLishUtils
extends Object

TestNG YAMLish utility class.

Since:
1.0

Field Summary
static SimpleDateFormat ISO_8061_DATE_FORMAT
          Date Format used to format a datetime in ISO-8061 for YAMLish diagnostic.
static String LINE_SEPARATOR
           
 
Method Summary
static String getActual(org.testng.ITestResult testNgTestResult)
           
static String getBacktrace(org.testng.ITestResult testNgTestResult)
           
static String getDatetime(org.testng.ITestResult testNgTestResult)
          Retrieves the date of the TestNG Test Result start time.
static String getDisplay(org.testng.ITestResult testNgTestResult)
          Returns YAMLish multi-line display entry.
static Object getDump(org.testng.ITestResult testNgTestResult)
           
static String getError(org.testng.ITestResult testNgTestResult)
           
static String getExpected(org.testng.ITestResult testNgTestResult)
           
static Object getExtensions(org.testng.ITestResult testNgTestResult)
           
static String getFile(org.testng.ITestResult testNgTestResult)
           
static String getLine(org.testng.ITestResult testNgTestResult)
           
static String getLineNumberFromExceptionTraceLine(String exceptionTraceLine, String substrToSearch)
          Get the error line number from the exception stack trace
static String getMessage(org.testng.ITestResult testNgTestResult)
           
static String getName(org.testng.ITestResult testNgTestResult)
           
static String getSeverity(org.testng.ITestResult testNgTestResult)
           
static String getSource(org.testng.ITestResult testNgTestResult)
           
static org.testng.xml.XmlSuite parse(String filePath, InputStream is)
           
static StringBuilder toYaml(org.testng.xml.XmlSuite suite)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ISO_8061_DATE_FORMAT

public static final SimpleDateFormat ISO_8061_DATE_FORMAT
Date Format used to format a datetime in ISO-8061 for YAMLish diagnostic.


LINE_SEPARATOR

public static final String LINE_SEPARATOR
Method Detail

getMessage

public static String getMessage(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Message value

getSeverity

public static String getSeverity(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Severity value

getSource

public static String getSource(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Source value

getDatetime

public static String getDatetime(org.testng.ITestResult testNgTestResult)
Retrieves the date of the TestNG Test Result start time.

Returns:
Datetime value

getFile

public static String getFile(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
File value

getLine

public static String getLine(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Line value

getLineNumberFromExceptionTraceLine

public static String getLineNumberFromExceptionTraceLine(String exceptionTraceLine,
                                                         String substrToSearch)
Get the error line number from the exception stack trace

Parameters:
exceptionTraceLine -
substrToSearch -
Returns:
error line number

getName

public static String getName(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Name value

getExtensions

public static Object getExtensions(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Extensions value

getExpected

public static String getExpected(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Expected value

getActual

public static String getActual(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Actual value

getDisplay

public static String getDisplay(org.testng.ITestResult testNgTestResult)
Returns YAMLish multi-line display entry.

Parameters:
testNgTestResult - TestNG TestResult
Returns:
YAMLish multi-line

getDump

public static Object getDump(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Dump value

getError

public static String getError(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Error value

getBacktrace

public static String getBacktrace(org.testng.ITestResult testNgTestResult)
Parameters:
testNgTestResult -
Returns:
Backtrace value

toYaml

public static StringBuilder toYaml(org.testng.xml.XmlSuite suite)

parse

public static org.testng.xml.XmlSuite parse(String filePath,
                                            InputStream is)
                                     throws FileNotFoundException
Parameters:
filePath -
is -
Returns:
XMLSuite
Throws:
FileNotFoundException


Copyright © 2010-2012 TupiLabs. All Rights Reserved.