Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: Enable insta's require_full_match #4509

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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
3 changes: 1 addition & 2 deletions .config/insta.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
behavior:
# Disabling because of issues with running on Windows
# force_update: true
require_full_match: true
review:
# The default (true) has a small performance hit and never needed for us
warn_undiscovered: false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,4 +214,3 @@ module default_db {
let main <[{*..}]> = default_db.tracks

----- stderr -----

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: prqlc/prqlc/tests/integration/queries.rs
expression: "# mssql:test\nfrom albums\nselect {\n title,\n title_and_spaces = f\" {title} \",\n low = title | text.lower,\n up = title | text.upper,\n ltrimmed = title | text.ltrim,\n rtrimmed = title | text.rtrim,\n trimmed = title | text.trim,\n len = title | text.length,\n subs = title | text.extract 2 5,\n replace = title | text.replace \"al\" \"PIKA\",\n}\nsort {title}\nfilter (title | text.starts_with \"Black\") || (title | text.contains \"Sabbath\") || (title | text.ends_with \"os\")\n"
expression: "# mssql:test\n# glaredb:skip — TODO: started raising an error on 2024-05-20; see `window.prql`\n# for more details\nfrom albums\nselect {\n title,\n title_and_spaces = f\" {title} \",\n low = title | text.lower,\n up = title | text.upper,\n ltrimmed = title | text.ltrim,\n rtrimmed = title | text.rtrim,\n trimmed = title | text.trim,\n len = title | text.length,\n subs = title | text.extract 2 5,\n replace = title | text.replace \"al\" \"PIKA\",\n}\nsort {title}\nfilter (title | text.starts_with \"Black\") || (title | text.contains \"Sabbath\") || (title | text.ends_with \"os\")\n"
input_file: prqlc/prqlc/tests/integration/queries/text_module.prql
---
WITH table_0 AS (
Expand Down Expand Up @@ -37,4 +37,3 @@ WHERE
OR title LIKE CONCAT('%', 'os')
ORDER BY
title

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: prqlc/prqlc/tests/integration/queries.rs
expression: "# mssql:skip Conversion(\"cannot interpret I64(Some(1)) as an i32 value\")', connection.rs:200:34\n# duckdb:skip problems with DISTINCT ON (duckdb internal error: [with INPUT_TYPE = int; RESULT_TYPE = unsigned char]: Assertion `min_val <= input' failed.)\n# clickhouse:skip problems with DISTINCT ON\n# postgres:skip problems with DISTINCT ON\nfrom tracks\ngroup genre_id (\n sort milliseconds\n derive {\n num = row_number this,\n total = count this,\n last_val = last track_id,\n }\n take 10\n)\nsort {genre_id, milliseconds}\nselect {track_id, genre_id, num, total, last_val}\nfilter genre_id >= 22\n"
expression: "# mssql:skip Conversion(\"cannot interpret I64(Some(1)) as an i32 value\")', connection.rs:200:34\n# duckdb:skip problems with DISTINCT ON (duckdb internal error: [with INPUT_TYPE = int; RESULT_TYPE = unsigned char]: Assertion `min_val <= input' failed.)\n# clickhouse:skip problems with DISTINCT ON\n# postgres:skip problems with DISTINCT ON\n# glaredb:skip — TODO: started raising an error on 2024-05-20, from https://github.com/PRQL/prql/actions/runs/9154902656/job/25198160283:\n # ERROR: This feature is not implemented: Unsupported ast node in sqltorel:\n # Substring { expr: Identifier(Ident { value: \"title\", quote_style: None }),\n # substring_from: Some(Value(Number(\"2\", false))), substring_for:\n # Some(Value(Number(\"5\", false))), special: true }\nfrom tracks\ngroup genre_id (\n sort milliseconds\n derive {\n num = row_number this,\n total = count this,\n last_val = last track_id,\n }\n take 10\n)\nsort {genre_id, milliseconds}\nselect {track_id, genre_id, num, total, last_val}\nfilter genre_id >= 22\n"
input_file: prqlc/prqlc/tests/integration/queries/window.prql
---
WITH table_0 AS (
Expand Down Expand Up @@ -56,4 +56,3 @@ FROM
ORDER BY
genre_id,
milliseconds

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: prqlc/prqlc/tests/integration/queries.rs
expression: "# mssql:test\nfrom albums\nselect {\n title,\n title_and_spaces = f\" {title} \",\n low = title | text.lower,\n up = title | text.upper,\n ltrimmed = title | text.ltrim,\n rtrimmed = title | text.rtrim,\n trimmed = title | text.trim,\n len = title | text.length,\n subs = title | text.extract 2 5,\n replace = title | text.replace \"al\" \"PIKA\",\n}\nsort {title}\nfilter (title | text.starts_with \"Black\") || (title | text.contains \"Sabbath\") || (title | text.ends_with \"os\")\n"
expression: "# mssql:test\n# glaredb:skip — TODO: started raising an error on 2024-05-20; see `window.prql`\n# for more details\nfrom albums\nselect {\n title,\n title_and_spaces = f\" {title} \",\n low = title | text.lower,\n up = title | text.upper,\n ltrimmed = title | text.ltrim,\n rtrimmed = title | text.rtrim,\n trimmed = title | text.trim,\n len = title | text.length,\n subs = title | text.extract 2 5,\n replace = title | text.replace \"al\" \"PIKA\",\n}\nsort {title}\nfilter (title | text.starts_with \"Black\") || (title | text.contains \"Sabbath\") || (title | text.ends_with \"os\")\n"
input_file: prqlc/prqlc/tests/integration/queries/text_module.prql
---
from albums
Expand All @@ -21,4 +21,3 @@ filter ((title | text.starts_with "Black") || (
title
text.contains "Sabbath"
)) || (title | text.ends_with "os")

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: prqlc/prqlc/tests/integration/queries.rs
expression: "# mssql:skip Conversion(\"cannot interpret I64(Some(1)) as an i32 value\")', connection.rs:200:34\n# duckdb:skip problems with DISTINCT ON (duckdb internal error: [with INPUT_TYPE = int; RESULT_TYPE = unsigned char]: Assertion `min_val <= input' failed.)\n# clickhouse:skip problems with DISTINCT ON\n# postgres:skip problems with DISTINCT ON\nfrom tracks\ngroup genre_id (\n sort milliseconds\n derive {\n num = row_number this,\n total = count this,\n last_val = last track_id,\n }\n take 10\n)\nsort {genre_id, milliseconds}\nselect {track_id, genre_id, num, total, last_val}\nfilter genre_id >= 22\n"
expression: "# mssql:skip Conversion(\"cannot interpret I64(Some(1)) as an i32 value\")', connection.rs:200:34\n# duckdb:skip problems with DISTINCT ON (duckdb internal error: [with INPUT_TYPE = int; RESULT_TYPE = unsigned char]: Assertion `min_val <= input' failed.)\n# clickhouse:skip problems with DISTINCT ON\n# postgres:skip problems with DISTINCT ON\n# glaredb:skip — TODO: started raising an error on 2024-05-20, from https://github.com/PRQL/prql/actions/runs/9154902656/job/25198160283:\n # ERROR: This feature is not implemented: Unsupported ast node in sqltorel:\n # Substring { expr: Identifier(Ident { value: \"title\", quote_style: None }),\n # substring_from: Some(Value(Number(\"2\", false))), substring_for:\n # Some(Value(Number(\"5\", false))), special: true }\nfrom tracks\ngroup genre_id (\n sort milliseconds\n derive {\n num = row_number this,\n total = count this,\n last_val = last track_id,\n }\n take 10\n)\nsort {genre_id, milliseconds}\nselect {track_id, genre_id, num, total, last_val}\nfilter genre_id >= 22\n"
input_file: prqlc/prqlc/tests/integration/queries/window.prql
---
from tracks
Expand All @@ -16,4 +16,3 @@ group genre_id (
sort {genre_id, milliseconds}
select {track_id, genre_id, num, total, last_val}
filter genre_id >= 22

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: prqlc/prqlc/tests/integration/queries.rs
expression: "# mssql:test\nfrom albums\nselect {\n title,\n title_and_spaces = f\" {title} \",\n low = title | text.lower,\n up = title | text.upper,\n ltrimmed = title | text.ltrim,\n rtrimmed = title | text.rtrim,\n trimmed = title | text.trim,\n len = title | text.length,\n subs = title | text.extract 2 5,\n replace = title | text.replace \"al\" \"PIKA\",\n}\nsort {title}\nfilter (title | text.starts_with \"Black\") || (title | text.contains \"Sabbath\") || (title | text.ends_with \"os\")\n"
expression: "# mssql:test\n# glaredb:skip — TODO: started raising an error on 2024-05-20; see `window.prql`\n# for more details\nfrom albums\nselect {\n title,\n title_and_spaces = f\" {title} \",\n low = title | text.lower,\n up = title | text.upper,\n ltrimmed = title | text.ltrim,\n rtrimmed = title | text.rtrim,\n trimmed = title | text.trim,\n len = title | text.length,\n subs = title | text.extract 2 5,\n replace = title | text.replace \"al\" \"PIKA\",\n}\nsort {title}\nfilter (title | text.starts_with \"Black\") || (title | text.contains \"Sabbath\") || (title | text.ends_with \"os\")\n"
input_file: prqlc/prqlc/tests/integration/queries/text_module.prql
---
Bach: The Brandenburg Concertos, Bach: The Brandenburg Concertos ,bach: the brandenburg concertos,BACH: THE BRANDENBURG CONCERTOS,Bach: The Brandenburg Concertos,Bach: The Brandenburg Concertos,Bach: The Brandenburg Concertos,31,ach: ,Bach: The Brandenburg Concertos
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: prqlc/prqlc/tests/integration/queries.rs
expression: "# mssql:skip Conversion(\"cannot interpret I64(Some(1)) as an i32 value\")', connection.rs:200:34\n# duckdb:skip problems with DISTINCT ON (duckdb internal error: [with INPUT_TYPE = int; RESULT_TYPE = unsigned char]: Assertion `min_val <= input' failed.)\n# clickhouse:skip problems with DISTINCT ON\n# postgres:skip problems with DISTINCT ON\nfrom tracks\ngroup genre_id (\n sort milliseconds\n derive {\n num = row_number this,\n total = count this,\n last_val = last track_id,\n }\n take 10\n)\nsort {genre_id, milliseconds}\nselect {track_id, genre_id, num, total, last_val}\nfilter genre_id >= 22\n"
expression: "# mssql:skip Conversion(\"cannot interpret I64(Some(1)) as an i32 value\")', connection.rs:200:34\n# duckdb:skip problems with DISTINCT ON (duckdb internal error: [with INPUT_TYPE = int; RESULT_TYPE = unsigned char]: Assertion `min_val <= input' failed.)\n# clickhouse:skip problems with DISTINCT ON\n# postgres:skip problems with DISTINCT ON\n# glaredb:skip — TODO: started raising an error on 2024-05-20, from https://github.com/PRQL/prql/actions/runs/9154902656/job/25198160283:\n # ERROR: This feature is not implemented: Unsupported ast node in sqltorel:\n # Substring { expr: Identifier(Ident { value: \"title\", quote_style: None }),\n # substring_from: Some(Value(Number(\"2\", false))), substring_for:\n # Some(Value(Number(\"5\", false))), special: true }\nfrom tracks\ngroup genre_id (\n sort milliseconds\n derive {\n num = row_number this,\n total = count this,\n last_val = last track_id,\n }\n take 10\n)\nsort {genre_id, milliseconds}\nselect {track_id, genre_id, num, total, last_val}\nfilter genre_id >= 22\n"
input_file: prqlc/prqlc/tests/integration/queries/window.prql
---
3219,22,1,17,3219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "prql version:\"0.11.4\"\n\nfrom employees\n"
expression: "prql version:\"0.11.5\"\n\nfrom employees\n"
---
SELECT
*
FROM
employees

Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "from db.artists\n"
expression: "from artists\n"
---
SELECT
*
FROM
artists

Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "from e = db.employees\nselect e.first_name\n"
expression: "from e = employees\nselect e.first_name\n"
---
SELECT
first_name
FROM
employees AS e

Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "from db.`artist tracks`\n"
expression: "from `artist tracks`\n"
---
SELECT
*
FROM
"artist tracks"

Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "from db.`artists.parquet`\n"
expression: "from `artists.parquet`\n"
---
SELECT
*
FROM
"artists.parquet"

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: web/book/tests/documentation/book.rs
expression: "let my_artists = [\n {artist=\"Miles Davis\"},\n {artist=\"Marvin Gaye\"},\n {artist=\"James Brown\"},\n]\n\nfrom db.artists\njoin my_artists (==artist)\njoin db.albums (==artist_id)\nselect {artists.artist_id, albums.title}\n"
expression: "let my_artists = [\n {artist=\"Miles Davis\"},\n {artist=\"Marvin Gaye\"},\n {artist=\"James Brown\"},\n]\n\nfrom artists\njoin my_artists (==artist)\njoin albums (==artist_id)\nselect {artists.artist_id, albums.title}\n"
---
WITH table_0 AS (
SELECT
Expand All @@ -27,4 +27,3 @@ FROM
artists
JOIN my_artists ON artists.artist = my_artists.artist
JOIN albums ON artists.artist_id = albums.artist_id

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: web/book/tests/documentation/book.rs
expression: "let top_50 = (\n from db.employees\n sort salary\n take 50\n aggregate {total_salary = sum salary}\n)\n\ntop_50 # Starts a new pipeline\n"
expression: "let top_50 = (\n from employees\n sort salary\n take 50\n aggregate {total_salary = sum salary}\n)\n\nfrom top_50 # Starts a new pipeline\n"
---
WITH table_0 AS (
SELECT
Expand All @@ -21,4 +21,3 @@ SELECT
total_salary
FROM
top_50

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: web/book/tests/documentation/book.rs
expression: "from db.employees\ntake 50\ninto first_50\n\nfirst_50\n"
expression: "from employees\ntake 50\ninto first_50\n\nfrom first_50\n"
---
WITH first_50 AS (
SELECT
Expand All @@ -14,4 +14,3 @@ SELECT
*
FROM
first_50

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
source: web/book/tests/documentation/book.rs
expression: "let grouping = s\"\"\"\n SELECT SUM(a)\n FROM tbl\n GROUP BY\n GROUPING SETS\n ((b, c, d), (d), (b, d))\n\"\"\"\n\ngrouping\n"
expression: "let grouping = s\"\"\"\n SELECT SUM(a)\n FROM tbl\n GROUP BY\n GROUPING SETS\n ((b, c, d), (d), (b, d))\n\"\"\"\n\nfrom grouping\n"
---
WITH table_0 AS (
SELECT
Expand All @@ -14,4 +14,3 @@ SELECT
*
FROM
table_0

Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "from db.employees\nselect department\ngroup employees.* (\n take 1\n)\n"
expression: "from employees\nselect department\ngroup employees.* (\n take 1\n)\n"
---
SELECT
DISTINCT department
FROM
employees

Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
source: web/book/tests/documentation/book.rs
expression: "from db.employees\ngroup employees.* (take 1)\n"
expression: "from employees\ngroup employees.* (take 1)\n"
---
SELECT
DISTINCT *
FROM
employees

Loading