forked from apache/spark
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SPARK-48844][FOLLOWUP][TESTS] Cleanup duplicated data resource files…
… in hive-thriftserver test ### What changes were proposed in this pull request? A follow up of SPARK-48844 to cleanup duplicated data resource files in hive-thriftserver test ### Why are the changes needed? code refactoring ### Does this PR introduce _any_ user-facing change? no ### How was this patch tested? new tests ### Was this patch authored or co-authored using generative AI tooling? no Closes apache#47480 from yaooqinn/SPARK-48844-F. Authored-by: Kent Yao <yao@apache.org> Signed-off-by: Kent Yao <yao@apache.org>
- Loading branch information
Showing
7 changed files
with
193 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 15 additions & 4 deletions
19
sql/core/src/test/resources/sql-tests/inputs/sql-on-files.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,30 @@ | ||
CREATE DATABASE IF NOT EXISTS sql_on_files; | ||
-- Parquet | ||
CREATE TABLE sql_on_files.test_parquet USING PARQUET AS SELECT 1; | ||
SELECT * FROM parquet.``; | ||
SELECT * FROM parquet.`/file/not/found`; | ||
SELECT * FROM parquet.`src/test/resources/test-data/dec-in-fixed-len.parquet` LIMIT 1; | ||
SELECT * FROM parquet.`${spark.sql.warehouse.dir}/sql_on_files.db/test_parquet`; | ||
DROP TABLE sql_on_files.test_parquet; | ||
|
||
-- ORC | ||
CREATE TABLE sql_on_files.test_orc USING ORC AS SELECT 1; | ||
SELECT * FROM orc.``; | ||
SELECT * FROM orc.`/file/not/found`; | ||
SELECT * FROM orc.`src/test/resources/test-data/before_1582_date_v2_4.snappy.orc` LIMIT 1; | ||
SELECT * FROM orc.`${spark.sql.warehouse.dir}/sql_on_files.db/test_orc`; | ||
DROP TABLE sql_on_files.test_orc; | ||
|
||
-- CSV | ||
CREATE TABLE sql_on_files.test_csv USING CSV AS SELECT 1; | ||
SELECT * FROM csv.``; | ||
SELECT * FROM csv.`/file/not/found`; | ||
SELECT * FROM csv.`src/test/resources/test-data/cars.csv` LIMIT 1; | ||
SELECT * FROM csv.`${spark.sql.warehouse.dir}/sql_on_files.db/test_csv`; | ||
DROP TABLE sql_on_files.test_csv; | ||
|
||
-- JSON | ||
CREATE TABLE sql_on_files.test_json USING JSON AS SELECT 1; | ||
SELECT * FROM json.``; | ||
SELECT * FROM json.`/file/not/found`; | ||
SELECT * FROM json.`src/test/resources/test-data/with-map-fields.json` LIMIT 1; | ||
SELECT * FROM json.`${spark.sql.warehouse.dir}/sql_on_files.db/test_json`; | ||
DROP TABLE sql_on_files.test_json; | ||
|
||
DROP DATABASE sql_on_files; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file removed
BIN
-201 Bytes
sql/hive-thriftserver/src/test/resources/test-data/before_1582_date_v2_4.snappy.orc
Binary file not shown.
This file was deleted.
Oops, something went wrong.
Binary file removed
BIN
-460 Bytes
sql/hive-thriftserver/src/test/resources/test-data/dec-in-fixed-len.parquet
Binary file not shown.
5 changes: 0 additions & 5 deletions
5
sql/hive-thriftserver/src/test/resources/test-data/with-map-fields.json
This file was deleted.
Oops, something went wrong.