Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .github/workflows/drivers-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,6 @@ on:
- 'true'
- 'false'

env:
USE_TESSERACT_SQL_PLANNER: false

jobs:
latest-tag-sha:
runs-on: ubuntu-24.04
Expand Down Expand Up @@ -268,6 +265,12 @@ jobs:
- snowflake-export-bucket-azure-via-storage-integration
- snowflake-export-bucket-gcs
- snowflake-export-bucket-gcs-prefix
use_tesseract_sql_planner: [ false ]
include:
- database: postgres
use_tesseract_sql_planner: true
- database: bigquery-export-bucket-gcs
use_tesseract_sql_planner: true
fail-fast: false

steps:
Expand Down Expand Up @@ -334,7 +337,7 @@ jobs:
(contains(env.CLOUD_DATABASES, matrix.database) && env.DRIVERS_TESTS_ATHENA_CUBEJS_AWS_KEY != '') ||
(!contains(env.CLOUD_DATABASES, matrix.database))
env:
DRIVERS_TESTS_CUBEJS_TESSERACT_SQL_PLANNER: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.use_tesseract_sql_planner || env.USE_TESSERACT_SQL_PLANNER }}
DRIVERS_TESTS_CUBEJS_TESSERACT_SQL_PLANNER: ${{ (github.event_name == 'workflow_dispatch' && github.event.inputs.use_tesseract_sql_planner) || matrix.use_tesseract_sql_planner }}

# Athena
DRIVERS_TESTS_ATHENA_CUBEJS_AWS_KEY: ${{ secrets.DRIVERS_TESTS_ATHENA_CUBEJS_AWS_KEY }}
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,11 @@ jobs:
'clickhouse', 'druid', 'elasticsearch', 'mssql', 'mysql', 'postgres', 'prestodb',
'mysql-aurora-serverless', 'crate', 'mongobi', 'firebolt', 'dremio', 'vertica'
]
use_tesseract_sql_planner: [ false ]
include:
- db: postgres
node-version: 22.x
use_tesseract_sql_planner: true
fail-fast: false

steps:
Expand Down Expand Up @@ -481,6 +486,8 @@ jobs:
(contains(env.CLOUD_DATABASES, matrix.db) && env.DRIVERS_TESTS_ATHENA_CUBEJS_AWS_KEY != '') ||
(!contains(env.CLOUD_DATABASES, matrix.db))
env:
CUBEJS_TESSERACT_SQL_PLANNER: ${{ matrix.use_tesseract_sql_planner }}

# Firebolt Integration
DRIVERS_TESTS_FIREBOLT_CUBEJS_FIREBOLT_ENGINE_NAME: ${{ secrets.DRIVERS_TESTS_FIREBOLT_CUBEJS_FIREBOLT_ENGINE_NAME }}
DRIVERS_TESTS_FIREBOLT_CUBEJS_DB_NAME: ${{ secrets.DRIVERS_TESTS_FIREBOLT_CUBEJS_DB_NAME }}
Expand Down
19 changes: 19 additions & 0 deletions packages/cubejs-testing-drivers/fixtures/bigquery.json
Original file line number Diff line number Diff line change
Expand Up @@ -172,5 +172,24 @@
"SQL API: Rollup with aliases",
"SQL API: Nested Rollup over asterisk",
"SQL API: Extended nested Rollup over asterisk"
],
"tesseractSkip": [
"querying Products: dimensions -- doesn't work wo ordering",
"querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- rounding in athena",
"querying ECommerce: total sales, total profit by month + order (date) + total -- doesn't work with the BigQuery",
"querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- noisy test",
"pre-aggregations Customers: running total without time dimension",
"querying BigECommerce: null boolean",
"querying BigECommerce: rolling count_distinct_approx window by 2 day",
"querying BigECommerce: rolling count_distinct_approx window by 2 week",
"querying BigECommerce: rolling count_distinct_approx window by 2 month",
"querying BigECommerce: totalProfitYearAgo",
"SQL API: post-aggregate percentage of total",
"SQL API: Simple Rollup",
"SQL API: Rollup over exprs",
"SQL API: Nested Rollup",
"SQL API: Nested Rollup with aliases",
"SQL API: Timeshift measure from cube",
"SQL API: SQL push down push to cube quoted alias"
]
}
18 changes: 18 additions & 0 deletions packages/cubejs-testing-drivers/fixtures/postgres.json
Original file line number Diff line number Diff line change
Expand Up @@ -162,5 +162,23 @@
"querying BigECommerce: rolling window by 2 day without date range",
"querying BigECommerce: rolling window by 2 month without date range",
"querying BigECommerce: rolling window YTD without date range"
],
"tesseractSkip": [
"querying Products: dimensions -- doesn't work wo ordering",
"querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- rounding in athena",
"querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- noisy test",
"pre-aggregations Customers: running total without time dimension",
"querying BigECommerce: totalProfitYearAgo",
"SQL API: post-aggregate percentage of total",
"SQL API: Simple Rollup",
"SQL API: Complex Rollup",
"SQL API: Rollup with aliases",
"SQL API: Rollup over exprs",
"SQL API: Nested Rollup",
"SQL API: Nested Rollup with aliases",
"SQL API: Nested Rollup over asterisk",
"SQL API: Extended nested Rollup over asterisk",
"SQL API: Timeshift measure from cube",
"SQL API: SQL push down push to cube quoted alias"
]
}
6 changes: 5 additions & 1 deletion packages/cubejs-testing-drivers/src/tests/testQueries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ export function testQueries(type: string, { includeIncrementalSchemaSuite, exten
describe(`Queries with the @cubejs-backend/${type}-driver${extendedEnv ? ` ${extendedEnv}` : ''}`, () => {
jest.setTimeout(60 * 5 * 1000);

const isTesseractEnv = process.env.DRIVERS_TESTS_CUBEJS_TESSERACT_SQL_PLANNER && process.env.DRIVERS_TESTS_CUBEJS_TESSERACT_SQL_PLANNER.toLowerCase() === 'true';

const fixtures = getFixtures(type, extendedEnv);
let client: CubeApi;
let driver: BaseDriver;
Expand Down Expand Up @@ -65,7 +67,9 @@ export function testQueries(type: string, { includeIncrementalSchemaSuite, exten
}

function execute(name: string, test: () => Promise<void>) {
if (fixtures.skip && fixtures.skip.indexOf(name) >= 0) {
if (!isTesseractEnv && fixtures.skip && fixtures.skip.indexOf(name) >= 0) {
it.skip(name, test);
} else if (isTesseractEnv && fixtures.tesseractSkip && fixtures.tesseractSkip.indexOf(name) >= 0) {
it.skip(name, test);
} else {
it(name, test);
Expand Down
1 change: 1 addition & 0 deletions packages/cubejs-testing-drivers/src/types/Fixture.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ export type Fixture = {
[cube: string]: [{ name: string, [prop: string]: unknown }],
},
skip?: string[],
tesseractSkip?: string[],
};
Loading