public interface ExpectedResults
getQuerySetID()
.
The queryidentifier
identify a unique query and corresponds to the expected results file.Modifier and Type | Field and Description |
---|---|
static String |
PROP_EXPECTED_RESULTS_DIR_LOC
The results location is where expected result files can be found
|
static String |
PROP_EXPECTED_RESULTS_ROOT_DIR
PROP_EXPECTED_RESULTS_ROOT_DIR , if specified, indicates the root directory
to be prepended to the PROP_EXPECTED_RESULTS_DIR_LOC to create the full
directory to find the expected results files. |
Modifier and Type | Method and Description |
---|---|
Object |
compareResults(String queryIdentifier,
String sql,
ResultSet resultSet,
Throwable actualException,
int testStatus,
boolean isOrdered,
int updateCnt,
boolean resultFromQuery)
Called to compare the
ResultSet from the executed query to the expected results
and return the errors. |
Object |
getMetaData(String queryidentifier) |
String |
getQuerySetID()
Return the unique identifier for this query set.
|
File |
getResultsFile(String queryidentifier)
Returns the
File location for the actual results for the specified
query identifier. |
boolean |
isExceptionExpected(String queryidentifier)
Indicates if a query expects to have an
Exception to be thrown when the
query is executed. |
boolean |
isExpectedResultsNeeded() |
static final String PROP_EXPECTED_RESULTS_DIR_LOC
static final String PROP_EXPECTED_RESULTS_ROOT_DIR
PROP_EXPECTED_RESULTS_ROOT_DIR
, if specified, indicates the root directory
to be prepended to the PROP_EXPECTED_RESULTS_DIR_LOC
to create the full
directory to find the expected results files.
This property is normally used during the nightly builds so that the query files
will coming from other projects.String getQuerySetID()
File getResultsFile(String queryidentifier) throws QueryTestFailedException
File
location for the actual results for the specified
query identifier.queryidentifier
- QueryTestFailedException
boolean isExpectedResultsNeeded()
Return true if the expected results file is needed in the test. Either
for comparison or generation. It will return false when
the option TestProperties.RESULT_MODES.NONE
boolean isExceptionExpected(String queryidentifier) throws QueryTestFailedException
Exception
to be thrown when the
query is executed.queryidentifier
- QueryTestFailedException
Object compareResults(String queryIdentifier, String sql, ResultSet resultSet, Throwable actualException, int testStatus, boolean isOrdered, int updateCnt, boolean resultFromQuery) throws QueryTestFailedException
ResultSet
from the executed query to the expected results
and return the errors.queryIdentifier
- sql
- resultSet
- actualException
- testStatus
- isOrdered
- updateCnt
- QueryTestFailedException
Copyright © 2019. All rights reserved.