Skip to content

Commit 10efbfa

Browse files
chore: Extract snapshot tests to different nox session
1 parent b0f16e6 commit 10efbfa

File tree

304 files changed

+310
-342
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

304 files changed

+310
-342
lines changed

noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -720,6 +720,11 @@ def unit_prerelease(session: nox.sessions.Session):
720720
prerelease(session, os.path.join("tests", "unit"))
721721

722722

723+
@nox.session(python=UNIT_TEST_PYTHON_VERSIONS[-1])
724+
def snapshot(session: nox.sessions.Session):
725+
run_unit(session, os.path.join("tests", "snapshot"))
726+
727+
723728
@nox.session(python=SYSTEM_TEST_PYTHON_VERSIONS[-1])
724729
def system_prerelease(session: nox.sessions.Session):
725730
"""Run the system test suite with prerelease dependencies."""
File renamed without changes.
File renamed without changes.

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_binary_compiler/test_corr/out.sql renamed to tests/snapshot/aggregations/snapshots/test_binary_compiler/test_corr/out.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ WITH `bfcte_0` AS (
1010
)
1111
SELECT
1212
`bfcol_2` AS `corr_col`
13-
FROM `bfcte_1`
13+
FROM `bfcte_1`

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_binary_compiler/test_cov/out.sql renamed to tests/snapshot/aggregations/snapshots/test_binary_compiler/test_cov/out.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ WITH `bfcte_0` AS (
1010
)
1111
SELECT
1212
`bfcol_2` AS `cov_col`
13-
FROM `bfcte_1`
13+
FROM `bfcte_1`

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_nullary_compiler/test_row_number/out.sql renamed to tests/snapshot/aggregations/snapshots/test_nullary_compiler/test_row_number/out.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ WITH `bfcte_0` AS (
2424
)
2525
SELECT
2626
`bfcol_32` AS `row_number`
27-
FROM `bfcte_1`
27+
FROM `bfcte_1`

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_nullary_compiler/test_row_number_with_window/out.sql renamed to tests/snapshot/aggregations/snapshots/test_nullary_compiler/test_row_number_with_window/out.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ WITH `bfcte_0` AS (
1010
)
1111
SELECT
1212
`bfcol_1` AS `row_number`
13-
FROM `bfcte_1`
13+
FROM `bfcte_1`

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_nullary_compiler/test_size/out.sql renamed to tests/snapshot/aggregations/snapshots/test_nullary_compiler/test_size/out.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ WITH `bfcte_0` AS (
2323
)
2424
SELECT
2525
`bfcol_32` AS `size`
26-
FROM `bfcte_1`
26+
FROM `bfcte_1`

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_ordered_unary_compiler/test_array_agg/out.sql renamed to tests/snapshot/aggregations/snapshots/test_ordered_unary_compiler/test_array_agg/out.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ WITH `bfcte_0` AS (
99
)
1010
SELECT
1111
`bfcol_1` AS `int64_col`
12-
FROM `bfcte_1`
12+
FROM `bfcte_1`

tests/unit/core/compile/sqlglot/aggregations/snapshots/test_ordered_unary_compiler/test_string_agg/out.sql renamed to tests/snapshot/aggregations/snapshots/test_ordered_unary_compiler/test_string_agg/out.sql

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,11 @@ WITH `bfcte_0` AS (
55
), `bfcte_1` AS (
66
SELECT
77
COALESCE(
8-
STRING_AGG(`string_col`, ','
9-
ORDER BY
10-
`string_col` IS NULL ASC,
11-
`string_col` ASC),
8+
STRING_AGG(`string_col` ORDER BY `string_col` IS NULL ASC, `string_col` ASC, ','),
129
''
1310
) AS `bfcol_1`
1411
FROM `bfcte_0`
1512
)
1613
SELECT
1714
`bfcol_1` AS `string_col`
18-
FROM `bfcte_1`
15+
FROM `bfcte_1`

0 commit comments

Comments
 (0)