Skip to content

Commit 60a582b

Browse files
committed
Update the build and test infra for connectors
## Description - Updated build.sbt to add new subprojects for connectors. - Updated the unidoc settings to make sure it ignores all the new kernel and connectors code. - Moved unidoc generation testing into an explicit separate step (explicitly call `sbt test unidoc` from run-tests.py) instead of implicitly via sbt task dependencies. - Disabled code coverage because it was having problems with scala-2.13 builds and we were not really using it anyways. - Added a new Github action for running all connector tests by copying the existing action from the connectors dir. - Renamed Spark test Github action file from tests.yaml to spark_tests.yaml - Increased SBT's Java heap size with .sbtoptions New and existing Github actions Closes delta-io#1845 GitOrigin-RevId: d195e7123e37aae67d117d434139f2f28e3c6f2b
1 parent 7a80c80 commit 60a582b

File tree

6 files changed

+707
-25
lines changed

6 files changed

+707
-25
lines changed
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: "Delta Connectors Tests"
2+
on: [push, pull_request]
3+
jobs:
4+
build:
5+
name: "Run tests"
6+
runs-on: ubuntu-20.04
7+
strategy:
8+
matrix:
9+
# These Scala versions must match those in the build.sbt
10+
scala: [2.13.5, 2.12.15]
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: install java
14+
uses: actions/setup-java@v2
15+
with:
16+
distribution: 'zulu'
17+
java-version: '8'
18+
- name: Cache Scala, SBT
19+
uses: actions/cache@v2
20+
with:
21+
path: |
22+
~/.sbt
23+
~/.ivy2
24+
~/.cache/coursier
25+
~/.m2
26+
key: build-cache-3-with-scala_${{ matrix.scala }}
27+
- name: Run Scala Style tests on test sources (Scala 2.12 only)
28+
run: build/sbt "++ ${{ matrix.scala }}" testScalastyle
29+
if: startsWith(matrix.scala, '2.12.')
30+
- name: Run sqlDeltaImport tests (Scala 2.12 and 2.13 only)
31+
run: build/sbt "++ ${{ matrix.scala }}" sqlDeltaImport/test
32+
if: ${{ !startsWith(matrix.scala, '2.11.') }}
33+
# These tests are not working yet
34+
# - name: Run Delta Standalone Compatibility tests (Scala 2.12 only)
35+
# run: build/sbt "++ ${{ matrix.scala }}" compatibility/test
36+
# if: startsWith(matrix.scala, '2.12.')
37+
- name: Run Delta Standalone tests
38+
run: build/sbt "++ ${{ matrix.scala }}" standalone/test testStandaloneCosmetic/test standaloneParquet/test testParquetUtilsWithStandaloneCosmetic/test
39+
- name: Run Hive 3 tests
40+
run: build/sbt "++ ${{ matrix.scala }}" hiveMR/test hiveTez/test
41+
- name: Run Hive 2 tests
42+
run: build/sbt "++ ${{ matrix.scala }}" hive2MR/test hive2Tez/test
43+
- name: Run Flink tests (Scala 2.12 only)
44+
run: build/sbt -mem 3000 "++ ${{ matrix.scala }}" flink/test
45+
if: ${{ startsWith(matrix.scala, '2.12.') }}

.github/workflows/test.yaml renamed to .github/workflows/spark_test.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ jobs:
55
runs-on: ubuntu-20.04
66
strategy:
77
matrix:
8+
# These Scala versions must match those in the build.sbt
89
scala: [2.12.15, 2.13.5]
910
env:
1011
SCALA_VERSION: ${{ matrix.scala }}
@@ -16,6 +17,7 @@ jobs:
1617
PATTERNS: |
1718
**
1819
!kernel/**
20+
!connectors/**
1921
- name: install java
2022
uses: actions/setup-java@v3
2123
with:
@@ -58,6 +60,6 @@ jobs:
5860
if: steps.git-diff.outputs.diff
5961
- name: Run Scala/Java and Python tests
6062
run: |
61-
pipenv run python run-tests.py --group spark --coverage
63+
pipenv run python run-tests.py --group spark
6264
cd examples/scala && build/sbt "++ $SCALA_VERSION compile"
6365
if: steps.git-diff.outputs.diff

.sbtopts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
-J-Xmx4G

0 commit comments

Comments
 (0)