Oracle Fusion Middleware extensions for Logging and Diagnostic
11g Release 1 (11.1.1.6)

E22565-06

oracle.apps.fnd.appltest.diagfwk.api.external
Class DiagnosticsTestFramework

java.lang.Object
  extended by oracle.apps.fnd.appltest.diagfwk.engine.facade.TestDefFacade
      extended by oracle.apps.fnd.appltest.diagfwk.api.external.DiagnosticsTestFramework

public class DiagnosticsTestFramework
extends TestDefFacade

This class is the Diagnostics Test Public API. Fusion framework or application that wants that access the Application Diagnostics Framework (or Oracle Diagnostics Framework, ODF), should use this public API instead of the facade classes, such as TestDefFacade and TestRunFacade, which are meant to be internal entry points.

Since:
11gR1
Version:
$Header: atgpf/appltest/applications/Diagnostics/Engine/src/oracle/apps/fnd/appltest/diagfwk/api/external/DiagnosticsTestFramework.java /main/7 2010/04/23 11:41:37 cshare Exp $
Author:
Oracle

Method Summary
static java.lang.String getODFDashboardURL()
          Gets the URL to the Diagnostics Dashboard UI application.
static java.lang.String getTestExecReportURL(java.lang.String executionId)
          Gets the URL to the Execution report for the given test execution ID.
static java.lang.String getTestRunReportURL(java.lang.String runId)
          Gets the URL to the Run report for the given run ID.
static TestRunStatus run(java.lang.String[] testNames, java.lang.String[] products, java.lang.String[] moduleIds, java.lang.String[] moduleKeys, java.lang.String[] tagNames, java.lang.String[] tagValues, java.lang.String runName, java.lang.Boolean recurse, java.lang.Boolean runPrereq, java.lang.Integer monitorInterval, java.lang.Integer numThreads, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams, java.lang.Boolean asynchronous)
          Run tests specified by test names, product, module id, module key, and/or tag name/value pair (one of those must not be null) with the given settings.
static TestRunStatus runByModuleId(java.lang.String[] moduleIds, java.lang.String runName, java.lang.Boolean recurse, java.lang.Boolean runPrereq, java.lang.Integer monitorInterval, java.lang.Integer numThreads, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams, java.lang.Boolean asynchronous)
          Run tests specified by the module id with the given settings.
static TestRunStatus runByModuleKey(java.lang.String[] moduleKeys, java.lang.String runName, java.lang.Boolean recurse, java.lang.Boolean runPrereq, java.lang.Integer monitorInterval, java.lang.Integer numThreads, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams, java.lang.Boolean asynchronous)
          Run tests specified by the module key with the given settings.
static TestRunStatus runByProduct(java.lang.String[] products, java.lang.String runName, java.lang.Boolean recurse, java.lang.Boolean runPrereq, java.lang.Integer monitorInterval, java.lang.Integer numThreads, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams, java.lang.Boolean asynchronous)
          Run tests specified by the product with the given settings.
static TestRunStatus runByTag(java.lang.String[] tagNames, java.lang.String[] tagValues, java.lang.String runName, java.lang.Boolean recurse, java.lang.Boolean runPrereq, java.lang.Integer monitorInterval, java.lang.Integer numThreads, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams, java.lang.Boolean asynchronous)
          Run tests specified by the tag name/value pair with the given settings.
static TestRunStatus runByTestName(java.lang.String[] testNames, java.lang.String runName, java.lang.Boolean recurse, java.lang.Boolean runPrereq, java.lang.Integer monitorInterval, java.lang.Integer numThreads, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams, java.lang.Boolean asynchronous)
          Run tests specified by the test names with the given settings.
static TestRunStatus statusByRunId(java.lang.String runId)
          Get the status of a test run given its id
static java.util.List<TestRunStatus> statusByRunName(java.lang.String runName)
          Get the list of the test statuses whose run name matches the given run name
 
Methods inherited from class oracle.apps.fnd.appltest.diagfwk.engine.facade.TestDefFacade
addTagToTests, computeInputsStatus, executeTestsForRun, getTestAvailabilityInfo, getWebApplicationsAvailableForTest, hasRequiredInputParams, prepareTreeNodes, queryInputOutputParams, queryInputParams, queryInputSets, queryPrereqTests, querySummary, queryTagValues, registerXMLTests, removeTagFromTests, runTests, runTests, runTests, runTests, unRegisterTests
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

runByTestName

public static TestRunStatus runByTestName(java.lang.String[] testNames,
                                          java.lang.String runName,
                                          java.lang.Boolean recurse,
                                          java.lang.Boolean runPrereq,
                                          java.lang.Integer monitorInterval,
                                          java.lang.Integer numThreads,
                                          java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams,
                                          java.lang.Boolean asynchronous)
Run tests specified by the test names with the given settings.

Parameters:
testNames - List of one or more names of the tests to run, must not be null or empty.
runName - The name of the test run, if null, this will be generated.
recurse - If TRUE, runs all tests associated with the specified taxonomy modules and/or diagnostic tags. If FALSE, runs only the tests immediately associated with the specified taxonomy modules and/or diagnostic tags. If null, defaults to TRUE.
runPrereq - If TRUE, performs a prerequisite analysis to identify any prerequisite tests and runs those prior to running the specified tests. If FALSE, runs only the specified tests. If null, defaults to FALSE
monitorInterval - The monitoring interval in seconds. This parameter specifies the interval in which the status of the run is uploaded to the test repository. If null, defaults to 30 seconds.
numThreads - The number of parallel threads that should be spawned to execute tests in this run. Specifying a value of 1 for this parameter will execute the tests serially. The value must be between 1 and the value specified in the system property "oracle.odf.run.maxthreads", or 100 if the system property is not set. If null, defaults to 5.
inputParams - For each test, a set of parameter values can be fed. Can be null.
asynchronous - If TRUE, tests are run asynchronously. Otherwise, they are run synchronously. If null, defaults to TRUE
Returns:
test run status
Throws:
DiagfwkException - if testNames is null or empty

runByProduct

public static TestRunStatus runByProduct(java.lang.String[] products,
                                         java.lang.String runName,
                                         java.lang.Boolean recurse,
                                         java.lang.Boolean runPrereq,
                                         java.lang.Integer monitorInterval,
                                         java.lang.Integer numThreads,
                                         java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams,
                                         java.lang.Boolean asynchronous)
Run tests specified by the product with the given settings.

Parameters:
products - List of products whose associated tests to run, must not be null or empty.
runName - The name of the test run, if null, this will be generated.
recurse - If TRUE, runs all tests associated with the specified taxonomy modules and/or diagnostic tags. If FALSE, runs only the tests immediately associated with the specified taxonomy modules and/or diagnostic tags. If null, defaults to TRUE.
runPrereq - If TRUE, performs a prerequisite analysis to identify any prerequisite tests and runs those prior to running the specified tests. If FALSE, runs only the specified tests. If null, defaults to FALSE
monitorInterval - The monitoring interval in seconds. This parameter specifies the interval in which the status of the run is uploaded to the test repository. If null, defaults to 30 seconds.
numThreads - The number of parallel threads that should be spawned to execute tests in this run. Specifying a value of 1 for this parameter will execute the tests serially. The value must be between 1 and the value specified in the system property "oracle.odf.run.maxthreads", or 100 if the system property is not set. If null, defaults to 5.
inputParams - For each test, a set of parameter values can be fed. Can be null.
asynchronous - If TRUE, tests are run asynchronously. Otherwise, they are run synchronously. If null, defaults to TRUE
Returns:
test run status
Throws:
DiagfwkException - if product is null

runByModuleId

public static TestRunStatus runByModuleId(java.lang.String[] moduleIds,
                                          java.lang.String runName,
                                          java.lang.Boolean recurse,
                                          java.lang.Boolean runPrereq,
                                          java.lang.Integer monitorInterval,
                                          java.lang.Integer numThreads,
                                          java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams,
                                          java.lang.Boolean asynchronous)
Run tests specified by the module id with the given settings.

Parameters:
moduleIds - List of module ids whose associated tests to run, must not be null or empty.
runName - The name of the test run, if null, this will be generated.
recurse - If TRUE, runs all tests associated with the specified taxonomy modules and/or diagnostic tags. If FALSE, runs only the tests immediately associated with the specified taxonomy modules and/or diagnostic tags. If null, defaults to TRUE.
runPrereq - If TRUE, performs a prerequisite analysis to identify any prerequisite tests and runs those prior to running the specified tests. If FALSE, runs only the specified tests. If null, defaults to FALSE
monitorInterval - The monitoring interval in seconds. This parameter specifies the interval in which the status of the run is uploaded to the test repository. If null, defaults to 30 seconds.
numThreads - The number of parallel threads that should be spawned to execute tests in this run. Specifying a value of 1 for this parameter will execute the tests serially. The value must be between 1 and the value specified in the system property "oracle.odf.run.maxthreads", or 100 if the system property is not set. If null, defaults to 5.
inputParams - For each test, a set of parameter values can be fed. Can be null.
asynchronous - If TRUE, tests are run asynchronously. Otherwise, they are run synchronously. If null, defaults to TRUE
Returns:
test run status
Throws:
DiagfwkException - if moduleId is null or invalid

runByModuleKey

public static TestRunStatus runByModuleKey(java.lang.String[] moduleKeys,
                                           java.lang.String runName,
                                           java.lang.Boolean recurse,
                                           java.lang.Boolean runPrereq,
                                           java.lang.Integer monitorInterval,
                                           java.lang.Integer numThreads,
                                           java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams,
                                           java.lang.Boolean asynchronous)
Run tests specified by the module key with the given settings.

Parameters:
moduleKeys - List of module keys whose associated tests to run, must not be null or empty.
runName - The name of the test run, if null, this will be generated.
recurse - If TRUE, runs all tests associated with the specified taxonomy modules and/or diagnostic tags. If FALSE, runs only the tests immediately associated with the specified taxonomy modules and/or diagnostic tags. If null, defaults to TRUE.
runPrereq - If TRUE, performs a prerequisite analysis to identify any prerequisite tests and runs those prior to running the specified tests. If FALSE, runs only the specified tests. If null, defaults to FALSE
monitorInterval - The monitoring interval in seconds. This parameter specifies the interval in which the status of the run is uploaded to the test repository. If null, defaults to 30 seconds.
numThreads - The number of parallel threads that should be spawned to execute tests in this run. Specifying a value of 1 for this parameter will execute the tests serially. The value must be between 1 and the value specified in the system property "oracle.odf.run.maxthreads", or 100 if the system property is not set. If null, defaults to 5.
inputParams - For each test, a set of parameter values can be fed. Can be null.
asynchronous - If TRUE, tests are run asynchronously. Otherwise, they are run synchronously. If null, defaults to TRUE
Returns:
test run status
Throws:
DiagfwkException - if moduleKey is null

runByTag

public static TestRunStatus runByTag(java.lang.String[] tagNames,
                                     java.lang.String[] tagValues,
                                     java.lang.String runName,
                                     java.lang.Boolean recurse,
                                     java.lang.Boolean runPrereq,
                                     java.lang.Integer monitorInterval,
                                     java.lang.Integer numThreads,
                                     java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams,
                                     java.lang.Boolean asynchronous)
Run tests specified by the tag name/value pair with the given settings.

Parameters:
tagNames - List of tag names whose associated tests to run, must not be null or empty. The size of tagNames must be equal to that of tagValues
tagValues - List of tag value whose associated tests to run, must not be null or empty. The size of tagNames must be equal to that of tagValues
runName - The name of the test run, if null, this will be generated.
recurse - If TRUE, runs all tests associated with the specified taxonomy modules and/or diagnostic tags. If FALSE, runs only the tests immediately associated with the specified taxonomy modules and/or diagnostic tags. If null, defaults to TRUE.
runPrereq - If TRUE, performs a prerequisite analysis to identify any prerequisite tests and runs those prior to running the specified tests. If FALSE, runs only the specified tests. If null, defaults to FALSE
monitorInterval - The monitoring interval in seconds. This parameter specifies the interval in which the status of the run is uploaded to the test repository. If null, defaults to 30 seconds.
numThreads - The number of parallel threads that should be spawned to execute tests in this run. Specifying a value of 1 for this parameter will execute the tests serially. The value must be between 1 and the value specified in the system property "oracle.odf.run.maxthreads", or 100 if the system property is not set. If null, defaults to 5.
inputParams - For each test, a set of parameter values can be fed. Can be null.
asynchronous - If TRUE, tests are run asynchronously. Otherwise, they are run synchronously. If null, defaults to TRUE
Returns:
test run status
Throws:
DiagfwkException - if tagName or tagValue is null

run

public static TestRunStatus run(java.lang.String[] testNames,
                                java.lang.String[] products,
                                java.lang.String[] moduleIds,
                                java.lang.String[] moduleKeys,
                                java.lang.String[] tagNames,
                                java.lang.String[] tagValues,
                                java.lang.String runName,
                                java.lang.Boolean recurse,
                                java.lang.Boolean runPrereq,
                                java.lang.Integer monitorInterval,
                                java.lang.Integer numThreads,
                                java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> inputParams,
                                java.lang.Boolean asynchronous)
Run tests specified by test names, product, module id, module key, and/or tag name/value pair (one of those must not be null) with the given settings.

Parameters:
testNames - List of one or more names of the tests to run.
products - List of products whose associated tests to run.
moduleIds - List of module ids whose associated tests to run.
moduleKeys - List of module keys whose associated tests to run.
tagNames - List of tag names whose associated tests to run. The size of tagNames must be equal to that of tagValues
tagValues - List of tag values whose associated tests to run. The size of tagNames must be equal to that of tagValues
runName - The name of the test run, if null, this will be generated.
recurse - If TRUE, runs all tests associated with the specified taxonomy modules and/or diagnostic tags. If FALSE, runs only the tests immediately associated with the specified taxonomy modules and/or diagnostic tags. If null, defaults to TRUE.
runPrereq - If TRUE, performs a prerequisite analysis to identify any prerequisite tests and runs those prior to running the specified tests. If FALSE, runs only the specified tests. If null, defaults to FALSE
monitorInterval - The monitoring interval in seconds. This parameter specifies the interval in which the status of the run is uploaded to the test repository. If null, defaults to 30 seconds.
numThreads - The number of parallel threads that should be spawned to execute tests in this run. Specifying a value of 1 for this parameter will execute the tests serially. The value must be between 1 and the value specified in the system property "oracle.odf.run.maxthreads", or 100 if the system property is not set. If null, defaults to 5.
inputParams - For each test, a set of parameter values can be fed. Can be null.
asynchronous - If TRUE, tests are run asynchronously. Otherwise, they are run synchronously. If null, defaults to TRUE
Returns:
test run status
Throws:
DiagfwkException - if all of the test-specifying parameters {testNames, product, moduleId, moduleKey, tagName/Value} are null or invalid, or if the run name is already used, or if the monitor interval is less than 0 or greater than 1 day or if the number of threads is less than 0 or greater than 100

statusByRunId

public static TestRunStatus statusByRunId(java.lang.String runId)
Get the status of a test run given its id

Parameters:
runId -
Returns:
test run status, null if no such run exists with the indicated id

statusByRunName

public static java.util.List<TestRunStatus> statusByRunName(java.lang.String runName)
Get the list of the test statuses whose run name matches the given run name

Parameters:
runName - the run name that can contain wild cards (i.e %)
Returns:
list of test run statuses, returns empty list if no such run exists with the indicated name

getTestRunReportURL

public static java.lang.String getTestRunReportURL(java.lang.String runId)
Gets the URL to the Run report for the given run ID.

Parameters:
runId - Run ID for which to get the run report URL.
Returns:
The URL to the run report for the given run ID. Returns null if the runId is invalid.
Throws:
DiagfwkException - when it is not able to construct the URL eventhough the runId is valid. This might happen in case the DIAGNOSTICS_DASHBOARD_URL profile option is not set or set to an invalid value.

getTestExecReportURL

public static java.lang.String getTestExecReportURL(java.lang.String executionId)
Gets the URL to the Execution report for the given test execution ID.

Parameters:
executionId - ID for the test execution.
Returns:
The URL to the execution report for the given execution ID. Returns null if the executionId is invalid.
Throws:
DiagfwkException - when it is not able to construct the URL eventhough the executionId is valid. This might happen in case the DIAGNOSTICS_DASHBOARD_URL profile option is not set or set to an invalid value.

getODFDashboardURL

public static java.lang.String getODFDashboardURL()
Gets the URL to the Diagnostics Dashboard UI application.

Returns:
the URL to the Diagnostics Dashboard UI application. The URL is determined by using applcore Topology API to get the deployment info

Oracle Fusion Middleware extensions for Logging and Diagnostic
11g Release 1 (11.1.1.6)

E22565-06

Copyright © 2012 Oracle. All Rights Reserved.