net.sf.farrago.test
Class FarragoSqlToRelTestBase

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.eigenbase.test.DiffTestCase
              extended by net.sf.farrago.test.ResultSetTestCase
                  extended by net.sf.farrago.test.FarragoTestCase
                      extended by net.sf.farrago.test.FarragoSqlToRelTestBase
All Implemented Interfaces:
Test
Direct Known Subclasses:
FarragoMetadataTest, FarragoOptRulesTest, FarragoRexToOJTranslatorTest, LoptMetadataTest

public abstract class FarragoSqlToRelTestBase
extends FarragoTestCase

FarragoSqlToRelTestBase is an abstract base for Farrago tests which involve conversion from SQL to relational algebra.

SQL statements to be translated use the normal test catalog.

Version:
$Id: //open/dev/farrago/src/net/sf/farrago/test/FarragoSqlToRelTestBase.java#15 $
Author:
John V. Sichi

Nested Class Summary
 
Nested classes/interfaces inherited from class net.sf.farrago.test.FarragoTestCase
FarragoTestCase.Cleanup, FarragoTestCase.CleanupFactory
 
Field Summary
 
Fields inherited from class net.sf.farrago.test.FarragoTestCase
allocOwner, connection, preparedStmt, repos, stmt, tracer
 
Fields inherited from class net.sf.farrago.test.ResultSetTestCase
resultSet
 
Fields inherited from class org.eigenbase.test.DiffTestCase
logFile, logOutputStream, refFile
 
Constructor Summary
protected FarragoSqlToRelTestBase(String testName)
           
 
Method Summary
protected  void addRulesAndCheckQuery(String explainQuery, List<RelOptRule> rules)
           
protected abstract  void checkAbstract(FarragoPreparingStmt stmt, RelNode topRel)
           
protected  void checkQuery(String explainQuery)
           
protected abstract  void initPlanner(FarragoPreparingStmt stmt)
           
 
Methods inherited from class net.sf.farrago.test.FarragoTestCase
forceShutdown, getJdbcUri, getSession, getTestlogRoot, getTestlogRootStatic, newConnection, newJdbcEngineDriver, restoreParameters, restoreParameters, runCleanup, runSqlLineTest, runSqlLineTest, saveParameters, saveParameters, setRefFileDiffMasks, setUp, shouldDiff, staticSetUp, staticTearDown, tearDown, tearDownImpl, wrappedSuite, wrappedSuite
 
Methods inherited from class net.sf.farrago.test.ResultSetTestCase
compareResultList, compareResultLists, compareResultSet, compareResultSetWithDelta, compareResultSetWithPattern, getResultSetCount
 
Methods inherited from class org.eigenbase.test.DiffTestCase
addDiffMask, addIgnorePattern, diffFile, diffLines, diffTestLog, fileContents, openTestLog, openTestLogOutputStream, setGC, setVerbose
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FarragoSqlToRelTestBase

protected FarragoSqlToRelTestBase(String testName)
                           throws Exception
Throws:
Exception
Method Detail

initPlanner

protected abstract void initPlanner(FarragoPreparingStmt stmt)
                             throws Exception
Throws:
Exception

checkAbstract

protected abstract void checkAbstract(FarragoPreparingStmt stmt,
                                      RelNode topRel)
                               throws Exception
Throws:
Exception

checkQuery

protected void checkQuery(String explainQuery)
                   throws Exception
Throws:
Exception

addRulesAndCheckQuery

protected void addRulesAndCheckQuery(String explainQuery,
                                     List<RelOptRule> rules)
                              throws Exception
Throws:
Exception