From e4c9e77fb58bf30d0322765150760bfa362736b0 Mon Sep 17 00:00:00 2001 From: Andrii Rosa Date: Mon, 12 Apr 2021 05:28:01 -0400 Subject: [PATCH] Run join, order by and window tests with Presto on Spark --- ...estPrestoSparkAbstractTestJoinQueries.java | 37 +++++++++++++++++++ ...PrestoSparkAbstractTestOrderByQueries.java | 25 +++++++++++++ ...tPrestoSparkAbstractTestWindowQueries.java | 25 +++++++++++++ 3 files changed, 87 insertions(+) create mode 100644 presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestJoinQueries.java create mode 100644 presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestOrderByQueries.java create mode 100644 presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestWindowQueries.java diff --git a/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestJoinQueries.java b/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestJoinQueries.java new file mode 100644 index 000000000000..7fc3f4cc0602 --- /dev/null +++ b/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestJoinQueries.java @@ -0,0 +1,37 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.facebook.presto.spark; + +import com.facebook.presto.tests.AbstractTestJoinQueries; + +public class TestPrestoSparkAbstractTestJoinQueries + extends AbstractTestJoinQueries +{ + protected TestPrestoSparkAbstractTestJoinQueries() + { + super(PrestoSparkQueryRunner::createHivePrestoSparkQueryRunner); + } + + @Override + public void testExecuteUsingComplexJoinCriteria() + { + // prepared statement is not supported by Presto on Spark + } + + @Override + public void testExecuteUsingWithSubqueryInJoin() + { + // prepared statement is not supported by Presto on Spark + } +} diff --git a/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestOrderByQueries.java b/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestOrderByQueries.java new file mode 100644 index 000000000000..6cd56117c5fb --- /dev/null +++ b/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestOrderByQueries.java @@ -0,0 +1,25 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.facebook.presto.spark; + +import com.facebook.presto.tests.AbstractTestOrderByQueries; + +public class TestPrestoSparkAbstractTestOrderByQueries + extends AbstractTestOrderByQueries +{ + protected TestPrestoSparkAbstractTestOrderByQueries() + { + super(PrestoSparkQueryRunner::createHivePrestoSparkQueryRunner); + } +} diff --git a/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestWindowQueries.java b/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestWindowQueries.java new file mode 100644 index 000000000000..12e5518ac63c --- /dev/null +++ b/presto-spark-base/src/test/java/com/facebook/presto/spark/TestPrestoSparkAbstractTestWindowQueries.java @@ -0,0 +1,25 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.facebook.presto.spark; + +import com.facebook.presto.tests.AbstractTestWindowQueries; + +public class TestPrestoSparkAbstractTestWindowQueries + extends AbstractTestWindowQueries +{ + protected TestPrestoSparkAbstractTestWindowQueries() + { + super(PrestoSparkQueryRunner::createHivePrestoSparkQueryRunner); + } +}