Skip to content

Commit 19f683f

Browse files
committed
Update integration tests to run for pulsar 3.0 and 4.0
1 parent c72255e commit 19f683f

2 files changed

Lines changed: 51 additions & 18 deletions

File tree

.github/workflows/github-ci.yml

Lines changed: 35 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ jobs:
3535
- name: Unit tests
3636
run: mvn -B test -DfailIfNoTests=false -pl streaming-ai,pulsar-transformations,pulsar-ai-tools -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
3737

38-
tests-ls:
39-
name: Integration tests on Luna Streaming
38+
tests-ls-31:
39+
name: Integration tests on Luna Streaming 3.1
4040
runs-on: ubuntu-latest
4141
needs: build
4242
steps:
@@ -58,11 +58,11 @@ jobs:
5858
- name: Build NAR
5959
run: mvn -B clean package -pl streaming-ai,pulsar-transformations -DskipTests -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
6060

61-
- name: Integration tests on Luna Streaming 2.10
62-
run: mvn -B test -DfailIfNoTests=false -pl tests -Dtest=DockerTest\$LunaStreaming210Test -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
61+
- name: Integration tests on Luna Streaming 3.1
62+
run: mvn -B test -DfailIfNoTests=false -pl tests -Dtest=DockerTest\$LunaStreaming31Test -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
6363

64-
tests-pulsar-211:
65-
name: Integration tests on Pulsar 2.11
64+
tests-ls-40:
65+
name: Integration tests on Luna Streaming 4.0
6666
runs-on: ubuntu-latest
6767
needs: build
6868
steps:
@@ -84,10 +84,10 @@ jobs:
8484
- name: Build NAR
8585
run: mvn -B clean package -pl streaming-ai,pulsar-transformations -DskipTests -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
8686

87-
- name: Integration tests on Pulsar 2.11
88-
run: mvn -B test -DfailIfNoTests=false -pl tests -Dtest=DockerTest\$Pulsar211Test -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
87+
- name: Integration tests on Luna Streaming 4.0
88+
run: mvn -B test -DfailIfNoTests=false -pl tests -Dtest=DockerTest\$LunaStreaming40Test -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
8989

90-
tests-pulsar-3:
90+
tests-pulsar-30:
9191
name: Integration tests on Pulsar 3.0
9292
runs-on: ubuntu-latest
9393
needs: build
@@ -112,3 +112,29 @@ jobs:
112112

113113
- name: Integration tests on Pulsar 3.0
114114
run: mvn -B test -DfailIfNoTests=false -pl tests -Dtest=DockerTest\$Pulsar30Test -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
115+
116+
tests-pulsar-40:
117+
name: Integration tests on Pulsar 4.0
118+
runs-on: ubuntu-latest
119+
needs: build
120+
steps:
121+
- uses: actions/checkout@v2
122+
- name: Set up JDK 11
123+
uses: actions/setup-java@v2
124+
with:
125+
java-version: '11'
126+
distribution: 'adopt'
127+
128+
- name: Cache local Maven repository
129+
uses: actions/cache@v3
130+
with:
131+
path: ~/.m2/repository
132+
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
133+
restore-keys: |
134+
${{ runner.os }}-maven-
135+
136+
- name: Build NAR
137+
run: mvn -B clean package -pl streaming-ai,pulsar-transformations -DskipTests -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip
138+
139+
- name: Integration tests on Pulsar 4.0
140+
run: mvn -B test -DfailIfNoTests=false -pl tests -Dtest=DockerTest\$Pulsar40Test -Dspotbugs.skip -Dlicense.skip -Dfmt.skip -Dxml-format.skip

tests/src/test/java/com/datastax/oss/pulsar/functions/transforms/tests/DockerTest.java

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,20 @@
1717

1818
public class DockerTest {
1919

20-
private static final String IMAGE_LUNASTREAMING210 = "datastax/lunastreaming:2.10_4.7";
21-
private static final String IMAGE_PULSAR211 = "apachepulsar/pulsar:2.11.1";
22-
private static final String IMAGE_PULSAR30 = "apachepulsar/pulsar:3.0.0";
20+
private static final String IMAGE_LUNASTREAMING31 = "datastax/lunastreaming:3.1.4_26";
21+
private static final String IMAGE_LUNASTREAMING40 = "datastax/lunastreaming:4.0.7_7";
22+
private static final String IMAGE_PULSAR30 = "apachepulsar/pulsar:3.0.17";
23+
private static final String IMAGE_PULSAR40 = "apachepulsar/pulsar:4.0.10";
2324

24-
public static class LunaStreaming210Test extends AbstractDockerTest {
25-
LunaStreaming210Test() {
26-
super(IMAGE_LUNASTREAMING210);
25+
public static class LunaStreaming31Test extends AbstractDockerTest {
26+
LunaStreaming31Test() {
27+
super(IMAGE_LUNASTREAMING31);
2728
}
2829
}
2930

30-
public static class Pulsar211Test extends AbstractDockerTest {
31-
Pulsar211Test() {
32-
super(IMAGE_PULSAR211);
31+
public static class LunaStreaming40Test extends AbstractDockerTest {
32+
LunaStreaming40Test() {
33+
super(IMAGE_LUNASTREAMING40);
3334
}
3435
}
3536

@@ -38,4 +39,10 @@ public static class Pulsar30Test extends AbstractDockerTest {
3839
super(IMAGE_PULSAR30);
3940
}
4041
}
42+
43+
public static class Pulsar40Test extends AbstractDockerTest {
44+
Pulsar40Test() {
45+
super(IMAGE_PULSAR40);
46+
}
47+
}
4148
}

0 commit comments

Comments
 (0)