Package | Description |
---|---|
org.testng | |
org.testng.internal | |
org.testng.reporters | |
org.testng.reporters.jq | |
org.testng.xml | |
org.testng.xml.dom |
Modifier and Type | Field and Description |
---|---|
private XmlSuite |
SuiteRunner.m_suite |
private XmlSuite |
SuiteResult.m_suite |
Modifier and Type | Field and Description |
---|---|
private java.util.List<XmlSuite> |
TestNG.m_cmdlineSuites |
protected java.util.List<XmlSuite> |
TestNG.m_suites |
Modifier and Type | Method and Description |
---|---|
private static XmlSuite |
TestNG.extractTestNames(XmlSuite s,
java.util.List<java.lang.String> testNames)
If the XmlSuite contains at least one test named as testNames, return
an XmlSuite that's made only of these tests, otherwise, return the
original suite.
|
XmlSuite |
SuiteResult.getSuite() |
XmlSuite |
SuiteRunner.getXmlSuite() |
XmlSuite |
ISuite.getXmlSuite() |
Modifier and Type | Method and Description |
---|---|
private java.util.List<XmlSuite> |
TestNG.createCommandLineSuitesForClasses(java.lang.Class[] classes) |
private java.util.List<XmlSuite> |
TestNG.createCommandLineSuitesForMethods(java.util.List<java.lang.String> commandLineMethods) |
Modifier and Type | Method and Description |
---|---|
void |
SuiteResultCounts.calculateResultCounts(XmlSuite xmlSuite,
SuiteRunnerMap suiteRunnerMap) |
private SuiteRunner |
TestNG.createSuiteRunner(XmlSuite xmlSuite)
Creates a suite runner and configures its initial state
|
private void |
TestNG.createSuiteRunners(SuiteRunnerMap suiteRunnerMap,
XmlSuite xmlSuite)
Creates the
SuiteRunner s and populates the suite runner map with
this information |
private static XmlSuite |
TestNG.extractTestNames(XmlSuite s,
java.util.List<java.lang.String> testNames)
If the XmlSuite contains at least one test named as testNames, return
an XmlSuite that's made only of these tests, otherwise, return the
original suite.
|
private static void |
TestNG.extractTestNamesFromChildSuites(XmlSuite s,
java.util.List<java.lang.String> testNames) |
private int |
TestNG.getVerbose(XmlSuite xmlSuite) |
private void |
SuiteRunner.init(IConfiguration configuration,
XmlSuite suite,
java.lang.String outputDir,
ITestRunnerFactory runnerFactory,
boolean useDefaultListeners,
java.util.List<IMethodInterceptor> methodInterceptors,
java.util.List<IInvokedMethodListener> invokedMethodListener,
java.util.List<ITestListener> testListeners,
java.util.List<IClassListener> classListeners) |
private void |
TestNG.populateSuiteGraph(DynamicGraph<ISuite> suiteGraph,
SuiteRunnerMap suiteRunnerMap,
XmlSuite xmlSuite)
Populates the dynamic graph with the reverse hierarchy of suites.
|
private void |
SuiteRunnerWorker.runSuite(SuiteRunnerMap suiteRunnerMap,
XmlSuite xmlSuite)
Runs a suite
|
private void |
TestNG.runSuitesSequentially(XmlSuite xmlSuite,
SuiteRunnerMap suiteRunnerMap,
int verbose,
java.lang.String defaultSuiteName)
Recursively runs suites.
|
void |
TestNG.setCommandLineSuite(XmlSuite suite) |
Modifier and Type | Method and Description |
---|---|
void |
IAlterSuiteListener.alter(java.util.List<XmlSuite> suites) |
private void |
TestNG.checkSuiteNames(java.util.List<XmlSuite> suites)
Ensure that two XmlSuite don't have the same name
Otherwise will be clash in SuiteRunnerMap
See issue #302
|
private void |
TestNG.checkSuiteNamesInternal(java.util.List<XmlSuite> suites,
java.util.Set<java.lang.String> names) |
private void |
TestNG.checkTestNames(java.util.List<XmlSuite> suites)
Ensure that two XmlTest within the same XmlSuite don't have the same name
|
private void |
Converter.findAllSuites(java.util.Collection<XmlSuite> suites,
java.util.Set<XmlSuite> result) |
private void |
Converter.findAllSuites(java.util.Collection<XmlSuite> suites,
java.util.Set<XmlSuite> result) |
void |
IReporter.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory)
Generate a report for the given suites into the specified output directory.
|
void |
TestNG.setXmlSuites(java.util.List<XmlSuite> suites)
Specifies the XmlSuite objects to run.
|
Constructor and Description |
---|
SuiteResult(XmlSuite suite,
ITestContext tr) |
SuiteRunner(IConfiguration configuration,
XmlSuite suite,
java.lang.String outputDir) |
SuiteRunner(IConfiguration configuration,
XmlSuite suite,
java.lang.String outputDir,
ITestRunnerFactory runnerFactory) |
SuiteRunner(IConfiguration configuration,
XmlSuite suite,
java.lang.String outputDir,
ITestRunnerFactory runnerFactory,
boolean useDefaultListeners) |
SuiteRunner(IConfiguration configuration,
XmlSuite suite,
java.lang.String outputDir,
ITestRunnerFactory runnerFactory,
boolean useDefaultListeners,
java.util.List<IMethodInterceptor> methodInterceptors,
java.util.List<IInvokedMethodListener> invokedMethodListeners,
java.util.List<ITestListener> testListeners,
java.util.List<IClassListener> classListeners) |
Modifier and Type | Field and Description |
---|---|
private XmlSuite |
TestMethodWorker.m_suite |
private XmlSuite |
TestMethodWithDataProviderMethodWorker.m_xmlSuite |
Modifier and Type | Method and Description |
---|---|
static XmlSuite |
Yaml.parse(java.lang.String filePath,
java.io.InputStream is) |
XmlSuite |
YamlParser.parse(java.lang.String filePath,
java.io.InputStream is,
boolean loadClasses) |
Modifier and Type | Method and Description |
---|---|
java.util.Collection<XmlSuite> |
OverrideProcessor.process(java.util.Collection<XmlSuite> suites) |
Modifier and Type | Method and Description |
---|---|
static java.lang.Object[] |
Parameters.createConfigurationParameters(java.lang.reflect.Method m,
java.util.Map<java.lang.String,java.lang.String> params,
java.lang.Object[] parameterValues,
ITestNGMethod currentTestMethod,
IAnnotationFinder finder,
XmlSuite xmlSuite,
ITestContext ctx,
ITestResult testResult)
Creates the parameters needed for the specified @Configuration
Method . |
static java.lang.Object[] |
Parameters.createInstantiationParameters(java.lang.reflect.Constructor ctor,
java.lang.String methodAnnotation,
IAnnotationFinder finder,
java.lang.String[] parameterNames,
java.util.Map<java.lang.String,java.lang.String> params,
XmlSuite xmlSuite)
Creates the parameters needed for constructing a test class instance.
|
private Invoker.ParameterBag |
Invoker.createParameters(ITestNGMethod testMethod,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.util.Map<java.lang.String,java.lang.String> allParameterNames,
XmlSuite suite,
ITestContext testContext,
java.lang.Object fedInstance) |
private static java.lang.Object[] |
Parameters.createParameters(java.lang.reflect.Method m,
Parameters.MethodParameters params,
IAnnotationFinder finder,
XmlSuite xmlSuite,
java.lang.Class annotationClass,
java.lang.String atName) |
private static java.lang.Object[] |
Parameters.createParameters(java.lang.String methodName,
java.lang.Class[] parameterTypes,
java.lang.String[] optionalValues,
java.lang.String methodAnnotation,
IAnnotationFinder finder,
java.lang.String[] parameterNames,
Parameters.MethodParameters params,
XmlSuite xmlSuite) |
private XmlClass[] |
Invoker.findClassesInSameTest(java.lang.Class<?> cls,
XmlSuite suite) |
ISuite |
SuiteRunnerMap.get(XmlSuite xmlSuite) |
private void |
Invoker.handleConfigurationFailure(java.lang.Throwable ite,
ITestNGMethod tm,
ITestResult testResult,
IConfigurationAnnotation annotation,
ITestNGMethod currentTestMethod,
java.lang.Object instance,
XmlSuite suite) |
private void |
Invoker.handleConfigurationSkip(ITestNGMethod tm,
ITestResult testResult,
IConfigurationAnnotation annotation,
ITestNGMethod currentTestMethod,
java.lang.Object instance,
XmlSuite suite)
Marks the current
TestResult as skipped and invokes the listeners. |
static ParameterHolder |
Parameters.handleParameters(ITestNGMethod testMethod,
java.util.Map<java.lang.String,java.lang.String> allParameterNames,
java.lang.Object instance,
Parameters.MethodParameters methodParams,
XmlSuite xmlSuite,
IAnnotationFinder annotationFinder,
java.lang.Object fedInstance)
If the method has parameters, fill them in.
|
private Invoker.ParameterBag |
Invoker.handleParameters(ITestNGMethod testMethod,
java.lang.Object instance,
java.util.Map<java.lang.String,java.lang.String> allParameterNames,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.Object[] parameterValues,
XmlSuite suite,
ITestContext testContext,
java.lang.Object fedInstance,
ITestResult testResult) |
private void |
Invoker.invokeAfterGroupsConfigurations(ITestClass testClass,
ITestNGMethod currentTestMethod,
ConfigurationGroupMethods groupMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> params,
java.lang.Object instance) |
private void |
Invoker.invokeBeforeGroupsConfigurations(ITestClass testClass,
ITestNGMethod currentTestMethod,
ConfigurationGroupMethods groupMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> params,
java.lang.Object instance)
Filter all the beforeGroups methods and invoke only those that apply
to the current test method
|
void |
Invoker.invokeConfigurations(IClass testClass,
ITestNGMethod[] allMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> params,
java.lang.Object[] parameterValues,
java.lang.Object instance)
Invoke configuration methods if they belong to the same TestClass passed
in parameter..
|
void |
IInvoker.invokeConfigurations(IClass testClass,
ITestNGMethod[] allMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.Object[] parameterValues,
java.lang.Object instance)
Invoke configuration methods if they belong to the same TestClass
passed in parameter..
|
private void |
Invoker.invokeConfigurations(IClass testClass,
ITestNGMethod currentTestMethod,
ITestNGMethod[] allMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> params,
java.lang.Object[] parameterValues,
java.lang.Object instance,
ITestResult testMethodResult) |
private ITestResult |
Invoker.invokeMethod(java.lang.Object instance,
ITestNGMethod tm,
java.lang.Object[] parameterValues,
int parametersIndex,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> params,
ITestClass testClass,
ITestNGMethod[] beforeMethods,
ITestNGMethod[] afterMethods,
ConfigurationGroupMethods groupMethods,
Invoker.FailureContext failureContext) |
private java.util.List<ITestResult> |
Invoker.invokePooledTestMethods(ITestNGMethod testMethod,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters,
ConfigurationGroupMethods groupMethods,
ITestContext testContext)
Invokes a method that has a specified threadPoolSize.
|
protected ITestResult |
Invoker.invokeTestMethod(java.lang.Object instance,
ITestNGMethod tm,
java.lang.Object[] parameterValues,
int parametersIndex,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> params,
ITestClass testClass,
ITestNGMethod[] beforeMethods,
ITestNGMethod[] afterMethods,
ConfigurationGroupMethods groupMethods,
Invoker.FailureContext failureContext)
invokeTestMethods() eventually converge here to invoke a single @Test method.
|
java.util.List<ITestResult> |
Invoker.invokeTestMethods(ITestNGMethod testMethod,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> testParameters,
ConfigurationGroupMethods groupMethods,
java.lang.Object instance,
ITestContext testContext)
Invoke all the test methods.
|
java.util.List<ITestResult> |
IInvoker.invokeTestMethods(ITestNGMethod testMethod,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters,
ConfigurationGroupMethods groupMethods,
java.lang.Object instance,
ITestContext testContext)
Invoke the given method
|
void |
SuiteRunnerMap.put(XmlSuite xmlSuite,
ISuite suite) |
private void |
Invoker.recordConfigurationInvocationFailed(ITestNGMethod tm,
IClass testClass,
IConfigurationAnnotation annotation,
ITestNGMethod currentTestMethod,
java.lang.Object instance,
XmlSuite suite)
Record internally the failure of a Configuration, so that we can determine
later if @Test should be skipped.
|
(package private) int |
Invoker.retryFailed(java.lang.Object instance,
ITestNGMethod tm,
XmlSuite suite,
ITestClass testClass,
ITestNGMethod[] beforeMethods,
ITestNGMethod[] afterMethods,
ConfigurationGroupMethods groupMethods,
java.util.List<ITestResult> result,
int failureCount,
ExpectedExceptionsHolder expectedExceptionHolder,
ITestContext testContext,
java.util.Map<java.lang.String,java.lang.String> parameters,
int parametersIndex) |
private java.util.List<ITestResult> |
Invoker.runWorkers(ITestNGMethod testMethod,
java.util.List<IWorker<ITestNGMethod>> workers,
int threadPoolSize,
ConfigurationGroupMethods groupMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters)
To reduce thread contention and also to correctly handle thread-confinement
this method invokes the @BeforeGroups and @AfterGroups corresponding to the current @Test method.
|
static java.lang.StringBuilder |
Yaml.toYaml(XmlSuite suite)
The main entry point to convert an XmlSuite into YAML.
|
Modifier and Type | Method and Description |
---|---|
java.util.Collection<XmlSuite> |
OverrideProcessor.process(java.util.Collection<XmlSuite> suites) |
Constructor and Description |
---|
SingleTestMethodWorker(IInvoker invoker,
MethodInstance testMethod,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters,
ITestContext testContext,
java.util.List<IClassListener> listeners) |
TestMethodWithDataProviderMethodWorker(Invoker invoker,
ITestNGMethod testMethod,
int parameterIndex,
java.lang.Object[] parameterValues,
java.lang.Object instance,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters,
ITestClass testClass,
ITestNGMethod[] beforeMethods,
ITestNGMethod[] afterMethods,
ConfigurationGroupMethods groupMethods,
ExpectedExceptionsHolder expectedExceptionHolder,
ITestContext testContext,
boolean skipFailedInvocationCounts,
int invocationCount,
int failureCount,
ITestResultNotifier notifier) |
TestMethodWorker(IInvoker invoker,
IMethodInstance[] testMethods,
XmlSuite suite,
java.util.Map<java.lang.String,java.lang.String> parameters,
ConfigurationGroupMethods groupMethods,
ClassMethodMap classMethodMap,
ITestContext testContext,
java.util.List<IClassListener> listeners) |
Modifier and Type | Field and Description |
---|---|
private XmlSuite |
FailedReporter.m_xmlSuite |
Modifier and Type | Method and Description |
---|---|
private void |
SuiteHTMLReporter.generateClasses(XmlSuite xmlSuite,
ISuite suite) |
private void |
SuiteHTMLReporter.generateExcludedMethodsReport(XmlSuite xmlSuite,
ISuite suite) |
protected void |
FailedReporter.generateFailureSuite(XmlSuite xmlSuite,
ISuite suite,
java.lang.String outputDir) |
private void |
SuiteHTMLReporter.generateIndex(XmlSuite xmlSuite,
ISuite sr) |
private void |
SuiteHTMLReporter.generateMain(XmlSuite xmlSuite,
ISuite sr) |
private void |
SuiteHTMLReporter.generateMethodsAndGroups(XmlSuite xmlSuite,
ISuite suite)
Generate information about methods and groups
|
private void |
SuiteHTMLReporter.generateMethodsChronologically(XmlSuite xmlSuite,
ISuite suite,
java.lang.String outputFileName,
boolean alphabetical) |
private void |
SuiteHTMLReporter.generateReporterOutput(XmlSuite xmlSuite,
ISuite suite) |
private void |
SuiteHTMLReporter.generateSuites(XmlSuite xmlSuite,
ISuite suite)
Writes a property file for each suite result.
|
private void |
SuiteHTMLReporter.generateTableOfContents(XmlSuite xmlSuite,
ISuite suite) |
private void |
SuiteHTMLReporter.generateXmlFile(XmlSuite xmlSuite,
ISuite suite) |
private java.lang.String |
SuiteHTMLReporter.getOutputDirectory(XmlSuite xmlSuite) |
private void |
XMLReporter.writeSuite(XmlSuite xmlSuite,
ISuite suite) |
Modifier and Type | Method and Description |
---|---|
void |
XMLReporter.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory) |
void |
SuiteHTMLReporter.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory) |
void |
JqReporter.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory) |
void |
JUnitReportReporter.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String defaultOutputDirectory) |
void |
FailedReporter.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory) |
void |
EmailableReporter2.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory) |
void |
EmailableReporter.generateReport(java.util.List<XmlSuite> xml,
java.util.List<ISuite> suites,
java.lang.String outdir)
Creates summary of the run
|
private XMLStringBuffer |
JqReporter.generateSuites(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
XMLStringBuffer main) |
Constructor and Description |
---|
FailedReporter(XmlSuite xmlSuite) |
Modifier and Type | Method and Description |
---|---|
void |
Main.generateReport(java.util.List<XmlSuite> xmlSuites,
java.util.List<ISuite> suites,
java.lang.String outputDirectory) |
Modifier and Type | Field and Description |
---|---|
private XmlSuite |
TestNGContentHandler.m_currentSuite |
private XmlSuite |
XmlSuite.m_parentSuite
Parent XML Suite if this suite was specified in another suite using
|
private XmlSuite |
XmlTest.m_suite |
Modifier and Type | Field and Description |
---|---|
private java.util.List<XmlSuite> |
XmlSuite.m_childSuites
List of child XML suite specified using
|
private java.util.List<XmlSuite> |
TestNGContentHandler.m_suites |
Modifier and Type | Method and Description |
---|---|
XmlSuite |
XmlSuite.getParentSuite() |
XmlSuite |
TestNGContentHandler.getSuite() |
XmlSuite |
XmlTest.getSuite()
Returns the suite this test is part of.
|
XmlSuite |
SuiteXmlParser.parse(java.lang.String currentFile,
java.io.InputStream inputStream,
boolean loadClasses) |
XmlSuite |
XmlSuite.shallowCopy()
This method returns a shallow cloned version.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<XmlSuite> |
XmlSuite.getChildSuites() |
java.util.Collection<XmlSuite> |
Parser.parse()
Parses the TestNG test suite and returns the corresponding XmlSuite,
and possibly, other XmlSuite that are pointed to by
|
java.util.List<XmlSuite> |
Parser.parseToList() |
java.util.Collection<XmlSuite> |
IPostProcessor.process(java.util.Collection<XmlSuite> suites) |
Modifier and Type | Method and Description |
---|---|
private void |
XmlTest.init(XmlSuite suite,
int index) |
void |
XmlSuite.setParentSuite(XmlSuite parentSuite) |
void |
XmlTest.setSuite(XmlSuite result) |
void |
XmlTest.setXmlSuite(XmlSuite suite) |
Modifier and Type | Method and Description |
---|---|
java.util.Collection<XmlSuite> |
IPostProcessor.process(java.util.Collection<XmlSuite> suites) |
Constructor and Description |
---|
XmlTest(XmlSuite suite) |
XmlTest(XmlSuite suite,
int index)
Constructs a
XmlTest and adds it to suite's list of tests. |
Modifier and Type | Method and Description |
---|---|
XmlSuite |
DomXmlParser.parse(java.lang.String currentFile,
java.io.InputStream inputStream,
boolean loadClasses) |
XmlSuite |
DomXmlParser.parse2(java.lang.String currentFile,
java.io.InputStream inputStream,
boolean loadClasses) |
Modifier and Type | Method and Description |
---|---|
void |
DomUtil.populate(XmlSuite xmlSuite) |
private static void |
XDom.test(XmlSuite s) |