Skip to content

Commit bb52174

Browse files
committed
GHA - Fix cache in CI, cleanup arg line
1 parent f770a75 commit bb52174

File tree

1 file changed

+6
-20
lines changed

1 file changed

+6
-20
lines changed

.github/workflows/ci.yaml

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,28 +20,14 @@ jobs:
2020
- name: Set up JDK ${{ matrix.java }} ${{ matrix.distribution }}
2121
uses: actions/setup-java@v4
2222
with:
23-
java-version: ${{ matrix.java }}
23+
cache: ${{ matrix.cache }}
2424
distribution: ${{ matrix.distribution }}
25-
- name: Print JDK Version
26-
run: java -version
27-
- name: Cache local Maven m2
28-
uses: actions/cache@v4
29-
with:
30-
path: ~/.m2
31-
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
32-
restore-keys: |
33-
${{ runner.os }}-m2
34-
- name: Skip tests that require illegal reflective access
25+
java-version: ${{ matrix.java }}
26+
- name: Setup skip tests that require illegal reflective access ubuntu
3527
if: ${{ matrix.os == 'ubuntu-latest' }}
36-
run: echo 'ARG_LINE=-D"excludedGroups=RequireIllegalAccess"' >> $GITHUB_ENV
37-
- name: Skip tests that require illegal reflective access
28+
run: echo 'ARG_LINE=-D"excludedGroups=RequireIllegalAccess" -Xmx2048m -javaagent:${settings.localRepository}/net/bytebuddy/byte-buddy-agent/${byte-buddy.version}/byte-buddy-agent-${byte-buddy.version}.jar' >> $GITHUB_ENV
29+
- name: Setup skip tests that require illegal reflective access not ubuntu
3830
if: ${{ matrix.os != 'ubuntu-latest' }}
39-
run: echo 'ARG_LINE=-D"excludedGroups=TestcontainersTests,RequireIllegalAccess"' >> $GITHUB_ENV
40-
- name: Active Profiles
41-
run: ./mvnw help:active-profiles
31+
run: echo 'ARG_LINE=-D"excludedGroups=TestcontainersTests,RequireIllegalAccess" -Xmx2048m -javaagent:${settings.localRepository}/net/bytebuddy/byte-buddy-agent/${byte-buddy.version}/byte-buddy-agent-${byte-buddy.version}.jar' >> $GITHUB_ENV
4232
- name: Test with Maven
43-
if: ${{ matrix.os != 'windows-latest' }}
4433
run: ./mvnw test -B -V --no-transfer-progress -D"license.skip=true" -D"jacoco.skip=true" $ARG_LINE
45-
- name: Test with Maven
46-
if: ${{ matrix.os == 'windows-latest' }}
47-
run: ./mvnw test -B -V --no-transfer-progress -D"license.skip=true" -D"jacoco.skip=true" -D"excludedGroups=TestcontainersTests,RequireIllegalAccess"

0 commit comments

Comments
 (0)