Package io.trino.testing
Class BaseConnectorSmokeTest
java.lang.Object
io.trino.testing.AbstractTestQueryFramework
io.trino.testing.BaseConnectorSmokeTest
A connector smoke test exercising various connector functionalities without going in depth on any of them.
A connector should implement
BaseConnectorTest and use this class to exercise some configuration variants.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringcreateSchemaSql(String schemaName) voidEnsure the tests are run withDistributedQueryRunner.voidprotected StringexpectedValues(String values) protected StringgetColumnComment(String tableName, String columnName) protected Stringprotected StringgetTableComment(String tableName) protected booleanhasBehavior(TestingConnectorBehavior connectorBehavior) Make sure to group related behaviours together in the order and grouping they are declared inTestingConnectorBehavior.voidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidtestJoin()voidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidThis seemingly duplicate test ofBaseConnectorTest.testShowInformationSchemaTables()is used in the context of this class in order to be able to test against a wider range of connector configurations.voidtestTopN()voidvoidvoidtestView()voidvoidMethods inherited from class io.trino.testing.AbstractTestQueryFramework
assertAccessAllowed, assertAccessAllowed, assertAccessDenied, assertAccessDenied, assertExplain, assertExplain, assertExplainAnalyze, assertExplainAnalyze, assertNoDataRead, assertQuery, assertQuery, assertQuery, assertQuery, assertQuery, assertQuery, assertQueryEventually, assertQueryFails, assertQueryFails, assertQueryFailsEventually, assertQueryOrdered, assertQueryOrdered, assertQueryOrdered, assertQueryOrdered, assertQueryReturnsEmptyResult, assertQueryReturnsEmptyResult, assertQueryStats, assertQuerySucceeds, assertQuerySucceeds, assertTableColumnNames, assertUpdate, assertUpdate, assertUpdate, assertUpdate, assertUpdate, assertUpdate, assertUpdate, close, closeAfterClass, computeActual, computeActual, computeExpected, computeScalar, computeScalar, createQueryRunner, executeExclusively, formatSqlText, getDistributedQueryRunner, getDynamicFilteringStats, getExplainPlan, getExplainPlan, getGraphvizExplainPlan, getNodeCount, getQualifiedTableName, getQueryRunner, getSession, init, inTransaction, newTransaction, noJoinReordering, noJoinReordering, query, query, searchScanFilterAndProjectOperatorStats, skipTestUnless
-
Field Details
-
REQUIRED_TPCH_TABLES
-
-
Constructor Details
-
BaseConnectorSmokeTest
public BaseConnectorSmokeTest()
-
-
Method Details
-
hasBehavior
Make sure to group related behaviours together in the order and grouping they are declared inTestingConnectorBehavior. -
createSchemaSql
-
ensureDistributedQueryRunner
public void ensureDistributedQueryRunner()Ensure the tests are run withDistributedQueryRunner. E.g.LocalQueryRunnertakes some shortcuts, not exercising certain aspects. -
ensureTestNamingConvention
public void ensureTestNamingConvention()- Overrides:
ensureTestNamingConventionin classAbstractTestQueryFramework
-
testSelect
public void testSelect() -
testPredicate
public void testPredicate() -
testLimit
public void testLimit() -
testTopN
public void testTopN() -
testAggregation
public void testAggregation() -
testHaving
public void testHaving() -
testJoin
public void testJoin() -
testCreateTable
public void testCreateTable() -
getCreateTableDefaultDefinition
-
expectedValues
-
testCreateTableAsSelect
public void testCreateTableAsSelect() -
testInsert
public void testInsert() -
verifySupportsDeleteDeclaration
public void verifySupportsDeleteDeclaration() -
verifySupportsRowLevelDeleteDeclaration
public void verifySupportsRowLevelDeleteDeclaration() -
testDeleteAllDataFromTable
public void testDeleteAllDataFromTable() -
testRowLevelDelete
public void testRowLevelDelete() -
testTruncateTable
public void testTruncateTable() -
testUpdate
public void testUpdate() -
testMerge
public void testMerge() -
testCreateSchema
public void testCreateSchema() -
testCreateSchemaWithNonLowercaseOwnerName
public void testCreateSchemaWithNonLowercaseOwnerName() -
testRenameSchema
public void testRenameSchema() -
testRenameTable
- Throws:
Exception
-
testRenameTableAcrossSchemas
- Throws:
Exception
-
testShowInformationSchemaTables
public void testShowInformationSchemaTables()This seemingly duplicate test ofBaseConnectorTest.testShowInformationSchemaTables()is used in the context of this class in order to be able to test against a wider range of connector configurations. -
testSelectInformationSchemaTables
public void testSelectInformationSchemaTables() -
testSelectInformationSchemaColumns
public void testSelectInformationSchemaColumns() -
testShowCreateTable
public void testShowCreateTable() -
testView
public void testView() -
testMaterializedView
public void testMaterializedView() -
testCommentView
public void testCommentView() -
testCommentViewColumn
public void testCommentViewColumn() -
testCommentMaterializedViewColumn
public void testCommentMaterializedViewColumn() -
getTableComment
-
getColumnComment
-