Skip to content

Commit afb08c7

Browse files
committed
[KYUUBI #2824] [TEST] Replace test tag ExtendedSQLTest by Slow
### _Why are the changes needed?_ Currently, we define a `ExtendedSQLTest` in `kyuubi-common` test sources, and use it to mark some slow test. This PR propose to replace `ExtendedSQLTest` by `Slow` which is provided by scalatest, then we can use the same tag to mark slow tests in some modules which does not depends on `kyuubi-common`, and then seperate them into independent CI job to reduce the CI time ### _How was this patch tested?_ - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible - [ ] Add screenshots for manual tests if appropriate - [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request Closes #2824 from pan3793/scalatest-tag. Closes #2824 2597863 [Cheng Pan] [TEST] Replace test tag ExtendedSQLTest by Slow Authored-by: Cheng Pan <chengpan@apache.org> Signed-off-by: Cheng Pan <chengpan@apache.org>
1 parent 8539a56 commit afb08c7

File tree

5 files changed

+17
-42
lines changed

5 files changed

+17
-42
lines changed

.github/workflows/master.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,17 +54,17 @@ jobs:
5454
- java: 8
5555
spark: '3.2'
5656
spark-archive: '-Dspark.archive.mirror=https://archive.apache.org/dist/spark/spark-3.0.3 -Dspark.archive.name=spark-3.0.3-bin-hadoop2.7.tgz'
57-
exclude-tags: '-Dmaven.plugin.scalatest.exclude.tags=org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.HudiTest,org.apache.kyuubi.tags.IcebergTest'
57+
exclude-tags: '-Dmaven.plugin.scalatest.exclude.tags=org.scalatest.tags.Slow,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.HudiTest,org.apache.kyuubi.tags.IcebergTest'
5858
comment: 'verify-spark-3.0'
5959
- java: 8
6060
spark: '3.2'
6161
spark-archive: '-Dspark.archive.mirror=https://archive.apache.org/dist/spark/spark-3.1.3 -Dspark.archive.name=spark-3.1.3-bin-hadoop3.2.tgz'
62-
exclude-tags: '-Dmaven.plugin.scalatest.exclude.tags=org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.HudiTest,org.apache.kyuubi.tags.IcebergTest'
62+
exclude-tags: '-Dmaven.plugin.scalatest.exclude.tags=org.scalatest.tags.Slow,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.HudiTest,org.apache.kyuubi.tags.IcebergTest'
6363
comment: 'verify-spark-3.1'
6464
- java: 8
6565
spark: '3.2'
6666
spark-archive: '-Dspark.archive.mirror=https://dist.apache.org/repos/dist/dev/spark/v3.3.0-rc5-bin -Dspark.archive.name=spark-3.3.0-bin-hadoop3.tgz'
67-
exclude-tags: '-Dmaven.plugin.scalatest.exclude.tags=org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.HudiTest,org.apache.kyuubi.tags.IcebergTest'
67+
exclude-tags: '-Dmaven.plugin.scalatest.exclude.tags=org.scalatest.tags.Slow,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.HudiTest,org.apache.kyuubi.tags.IcebergTest'
6868
comment: 'verify-spark-3.3'
6969
env:
7070
SPARK_LOCAL_IP: localhost

kyuubi-common/src/test/java/org/apache/kyuubi/tags/ExtendedSQLTest.java

Lines changed: 0 additions & 29 deletions
This file was deleted.

kyuubi-server/src/test/scala/org/apache/kyuubi/operation/tpcds/DDLTPCDSSuite.scala

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,15 @@
1717

1818
package org.apache.kyuubi.operation.tpcds
1919

20+
import org.scalatest.tags.Slow
21+
2022
import org.apache.kyuubi.{DeltaSuiteMixin, WithKyuubiServer}
2123
import org.apache.kyuubi.config.KyuubiConf
2224
import org.apache.kyuubi.operation.HiveJDBCTestHelper
23-
import org.apache.kyuubi.tags.{DeltaTest, ExtendedSQLTest}
25+
import org.apache.kyuubi.tags.DeltaTest
2426

27+
@Slow
2528
@DeltaTest
26-
@ExtendedSQLTest
2729
class DDLTPCDSSuite extends WithKyuubiServer
2830
with HiveJDBCTestHelper
2931
with TPCDSHelper

kyuubi-server/src/test/scala/org/apache/kyuubi/operation/tpcds/OutputSchemaTPCDSSuite.scala

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,12 @@ package org.apache.kyuubi.operation.tpcds
2020
import java.nio.charset.StandardCharsets
2121
import java.nio.file.{Files, Path, Paths}
2222

23+
import org.scalatest.tags.Slow
24+
2325
import org.apache.kyuubi.{DeltaSuiteMixin, WithKyuubiServer}
2426
import org.apache.kyuubi.config.KyuubiConf
2527
import org.apache.kyuubi.server.mysql.MySQLJDBCTestHelper
26-
import org.apache.kyuubi.tags.{DeltaTest, ExtendedSQLTest}
28+
import org.apache.kyuubi.tags.DeltaTest
2729

2830
// scalastyle:off line.size.limit
2931
/**
@@ -42,8 +44,8 @@ import org.apache.kyuubi.tags.{DeltaTest, ExtendedSQLTest}
4244
* }}}
4345
*/
4446
// scalastyle:on line.size.limit
47+
@Slow
4548
@DeltaTest
46-
@ExtendedSQLTest
4749
class OutputSchemaTPCDSSuite extends WithKyuubiServer
4850
with MySQLJDBCTestHelper
4951
with TPCDSHelper

pom.xml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@
195195
<maven.plugin.scala.version>4.6.1</maven.plugin.scala.version>
196196
<maven.plugin.surefire.version>2.22.0</maven.plugin.surefire.version>
197197
<maven.plugin.scalatest.version>2.0.2</maven.plugin.scalatest.version>
198-
<maven.plugin.scalatest.exclude.tags>org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
198+
<maven.plugin.scalatest.exclude.tags>org.scalatest.tags.Slow,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
199199
<maven.plugin.scalatest.include.tags></maven.plugin.scalatest.include.tags>
200200
<maven.plugin.spotless.version>2.17.4</maven.plugin.spotless.version>
201201
<maven.plugin.jacoco.version>0.8.7</maven.plugin.jacoco.version>
@@ -1947,7 +1947,7 @@
19471947
https://hudi.apache.org/releases/release-0.11.0/#bundle-usage-updates
19481948
Hudi 0.11.0 Spark bundle for 3.0.x is no longer officially supported.
19491949
-->
1950-
<maven.plugin.scalatest.exclude.tags>org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
1950+
<maven.plugin.scalatest.exclude.tags>org.scalatest.tags.Slow,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
19511951
</properties>
19521952
</profile>
19531953

@@ -1957,7 +1957,7 @@
19571957
<spark.version>3.1.3</spark.version>
19581958
<delta.version>1.0.1</delta.version>
19591959
<iceberg.name>iceberg-spark-runtime-3.1_${scala.binary.version}</iceberg.name>
1960-
<maven.plugin.scalatest.exclude.tags>org.apache.kyuubi.tags.ExtendedSQLTest</maven.plugin.scalatest.exclude.tags>
1960+
<maven.plugin.scalatest.exclude.tags>org.scalatest.tags.Slow</maven.plugin.scalatest.exclude.tags>
19611961
</properties>
19621962
<modules>
19631963
<module>extensions/spark/kyuubi-extension-spark-common</module>
@@ -1976,7 +1976,7 @@
19761976
See https://github.com/apache/incubator-kyuubi/pull/2576
19771977
Hudi 0.11 requires hudi-spark3.2-bundle to execute UT
19781978
-->
1979-
<maven.plugin.scalatest.exclude.tags>org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
1979+
<maven.plugin.scalatest.exclude.tags>org.scalatest.tags.Slow,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
19801980
</properties>
19811981
<modules>
19821982
<module>extensions/spark/kyuubi-extension-spark-common</module>
@@ -2003,7 +2003,7 @@
20032003
<spark.version>3.3.0</spark.version>
20042004
<spark.archive.name>spark-${spark.version}-bin-hadoop3.tgz</spark.archive.name>
20052005
<spark.archive.mirror>https://dist.apache.org/repos/dist/dev/spark/v3.3.0-rc5-bin/</spark.archive.mirror>
2006-
<maven.plugin.scalatest.exclude.tags>org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.IcebergTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
2006+
<maven.plugin.scalatest.exclude.tags>org.scalatest.tags.Slow,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.IcebergTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
20072007
</properties>
20082008
<modules>
20092009
<module>extensions/spark/kyuubi-extension-spark-common</module>
@@ -2028,7 +2028,7 @@
20282028
</repositories>
20292029
<properties>
20302030
<spark.version>3.4.0-SNAPSHOT</spark.version>
2031-
<maven.plugin.scalatest.exclude.tags>org.apache.kyuubi.tags.ExtendedSQLTest,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.IcebergTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
2031+
<maven.plugin.scalatest.exclude.tags>org.scalatest.tags.Slow,org.apache.kyuubi.tags.DeltaTest,org.apache.kyuubi.tags.IcebergTest,org.apache.kyuubi.tags.HudiTest</maven.plugin.scalatest.exclude.tags>
20322032
</properties>
20332033
</profile>
20342034

0 commit comments

Comments
 (0)