Skip to content

Commit bfdb4ca

Browse files
authored
Merge pull request #222 from psycho-ir/master
Run integration tests on every build
2 parents 86954f4 + dbcb8ac commit bfdb4ca

File tree

2 files changed

+33
-3
lines changed

2 files changed

+33
-3
lines changed

.github/workflows/ci.yml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,27 @@ jobs:
1111
strategy:
1212
matrix:
1313
java: [8, 11, 15]
14+
kubernetes: ['v1.17.13','v1.18.12','v1.19.4']
1415
steps:
1516
- uses: actions/checkout@v2
1617
- uses: actions/cache@v2
1718
with:
1819
path: ~/.m2/repository
1920
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
2021
restore-keys: |
21-
${{ runner.os }}-maven-
22+
${{ runner.os }}-maven-
2223
- name: Set up JDK
2324
uses: actions/setup-java@v1
2425
with:
2526
java-version: ${{ matrix.java }}
26-
- name: Build with Maven
27-
run: mvn -B package -P no-integration-tests --file pom.xml
27+
- name: Run unit tests
28+
run: mvn -B test -P no-integration-tests --file pom.xml
29+
- name: Set up Minikube
30+
uses: manusa/actions-setup-minikube@v2.0.1
31+
with:
32+
minikube version: 'v1.15.0'
33+
kubernetes version: ${{ matrix.kubernetes }}
34+
driver: 'docker'
35+
- name: Run integration tests
36+
run: mvn -B package -P no-unit-tests --file pom.xml
37+

pom.xml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,26 @@
152152
</plugins>
153153
</build>
154154
</profile>
155+
<profile>
156+
<id>no-unit-tests</id>
157+
<build>
158+
<plugins>
159+
<plugin>
160+
<groupId>org.apache.maven.plugins</groupId>
161+
<artifactId>maven-surefire-plugin</artifactId>
162+
<version>${surefire.version}</version>
163+
<configuration>
164+
<includes>
165+
<exclude>**/*IT.java</exclude>
166+
</includes>
167+
<excludes>
168+
<include>**/*Test.java</include>
169+
</excludes>
170+
</configuration>
171+
</plugin>
172+
</plugins>
173+
</build>
174+
</profile>
155175
<profile>
156176
<id>release</id>
157177
<build>

0 commit comments

Comments
 (0)