File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ on :
2+ push :
3+ branches :
4+ - ' **'
5+ pull_request :
6+ types : [opened, synchronize, reopened]
7+
8+ name : Tests
9+ jobs :
10+ tests :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - uses : actions/checkout@v4
14+
15+ - name : Set up JDK 25
16+ uses : actions/setup-java@v4
17+ with :
18+ distribution : " temurin"
19+ java-version : 25
20+ overwrite-settings : false
21+
22+ - name : Cache Maven packages
23+ uses : actions/cache@v4
24+ with :
25+ path : ~/.m2/repository
26+ key : ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
27+ restore-keys : ${{ runner.os }}-maven
28+
29+ - name : Prepare test properties
30+ run : |
31+ mkdir -p src/test/resources
32+ echo ${{ secrets.APPLICATION_TEST_PROPERTIES }} | base64 -d > src/test/resources/application-test.properties
33+ echo "spring.sql.init.mode=never" >> src/test/resources/application-test.properties
34+
35+ - name : Prepare Docker .env for CI tests
36+ run : |
37+ cat > .env <<EOF
38+ POSTGRES_USER=${{ secrets.POSTGRES_USER }}
39+ POSTGRES_PASSWORD=${{ secrets.POSTGRES_PASSWORD }}
40+ POSTGRES_DB=${{ secrets.POSTGRES_DB }}
41+ POSTGRES_PORT=${{ secrets.POSTGRES_PORT }}
42+ EOF
43+
44+ - name : Install Docker Compose
45+ run : |
46+ sudo apt-get update
47+ sudo apt-get install -y docker-compose
48+
49+ - name : Run unit and integration tests
50+ run : ./mvnw clean verify
Original file line number Diff line number Diff line change 147147 <groupId >org.apache.maven.plugins</groupId >
148148 <artifactId >maven-surefire-plugin</artifactId >
149149 <configuration >
150- <skip >true</skip >
150+ <excludes >
151+ <exclude >**/*IntegrationTest.java</exclude >
152+ </excludes >
151153 </configuration >
152154 </plugin >
153155 <plugin >
154156 <groupId >org.apache.maven.plugins</groupId >
155157 <artifactId >maven-failsafe-plugin</artifactId >
156158 <configuration >
157159 <includes >
158- <include >**/*Tests.java</include >
159- <include >**/*Test.java</include >
160+ <include >**/*IntegrationTest.java</include >
160161 </includes >
161162 </configuration >
162163 <executions >
You can’t perform that action at this time.
0 commit comments