|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.tap4j.ext.testng.TestNGTapUtils
public final class TestNGTapUtils
Utility class with methods to support TAP generation with TestNG.
Field Summary | |
---|---|
static Comparator<org.testng.ITestResult> |
EXECUTION_DATE_COMPARATOR
A constant that defines a comparator for TestNG TestResults. |
Method Summary | |
---|---|
static void |
addAll(org.testng.internal.ResultMap total,
org.testng.IResultMap map)
Adds all ITestResult's inside the map object inside the total one. |
static void |
createTestNGYAMLishData(TestResult testResult,
org.testng.ITestResult testNgTestResult)
Inserts TestNG YAMLish diagnostic information into a TAP TestResult. |
static void |
createYAMLishActualAndExpected(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishBacktrace(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishDatetime(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishDisplay(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishDump(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishError(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishExtensions(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
Creates YAMLish diagnostic extensions entry data. |
static void |
createYAMLishFile(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishLine(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishMessage(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishName(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishSeverity(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
createYAMLishSource(Map<String,Object> yamlish,
org.testng.ITestResult testNgTestResult)
|
static void |
fillAttributes(org.testng.ITestResult tr,
org.testng.ITestContext ctx)
Fills the TestNG Attributes from the context into the TestNG Test Result. |
static TestResult |
generateTAPTestResult(org.testng.ITestResult testResult,
Integer number)
Generates a TAP TestResult from a given TestNG TestResult. |
static String |
generateTAPTestResultDescription(org.testng.ITestResult testResult)
Generates a TAP TestResult description with full qualified class name concatenated with the character '#' and the test method. |
static List<org.testng.ITestResult> |
getTestNGResultsOrderedByExecutionDate(org.testng.ITestContext testContext)
Return an ordered list of TestNG TestResult from a given TestNG Test Context. |
static List<org.testng.ITestResult> |
getTestNGResultsOrderedByExecutionDate(org.testng.internal.ResultMap total)
Return an ordered list of TestNG TestResult from a given TestNG Test Context. |
static void |
setTapTestResultStatus(TestResult tapTestResult,
int status)
Sets the StatusValue into a TAP TestResult. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final Comparator<org.testng.ITestResult> EXECUTION_DATE_COMPARATOR
Method Detail |
---|
public static TestResult generateTAPTestResult(org.testng.ITestResult testResult, Integer number)
testResult
- TestNG Test Resultnumber
- TAP Test Number
public static String generateTAPTestResultDescription(org.testng.ITestResult testResult)
testResult
- TestNG TestResult
public static void setTapTestResultStatus(TestResult tapTestResult, int status)
tapTestResult
- TAP TestResultstatus
- TestNG Test Status (Success, Skip, or any other that is
treated as Failed in TAP)public static void createTestNGYAMLishData(TestResult testResult, org.testng.ITestResult testNgTestResult)
Inserts TestNG YAMLish diagnostic information into a TAP TestResult.
For more about TAP YAMLish diagnostic read this Wiki.
testResult
- TAP TestResulttestNgTestResult
- TestNG TestResultpublic static void createYAMLishMessage(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishSeverity(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishSource(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishDatetime(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishFile(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishLine(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishName(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishExtensions(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- YAMLish MaptestNgTestResult
- TestNG TestResultpublic static void createYAMLishActualAndExpected(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishDisplay(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishDump(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishError(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static void createYAMLishBacktrace(Map<String,Object> yamlish, org.testng.ITestResult testNgTestResult)
yamlish
- testNgTestResult
- public static List<org.testng.ITestResult> getTestNGResultsOrderedByExecutionDate(org.testng.ITestContext testContext)
testContext
- TestNG Test Context
public static List<org.testng.ITestResult> getTestNGResultsOrderedByExecutionDate(org.testng.internal.ResultMap total)
total
- TestNG Result Map
public static void addAll(org.testng.internal.ResultMap total, org.testng.IResultMap map)
total
- ResultMap that holds the total of IResultMap's.map
- An IResultMap object.public static void fillAttributes(org.testng.ITestResult tr, org.testng.ITestContext ctx)
tr
- ctx
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |