Skip to content

Commit eae07db

Browse files
committed
Can't run tests against Java 8 because of Mockito 5
1 parent cf6c10f commit eae07db

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ jobs:
7575
uses: actions/setup-java@v5
7676
with:
7777
java-version: |
78-
8
78+
11
7979
23
8080
distribution: "temurin"
8181

@@ -113,12 +113,16 @@ jobs:
113113
--dynamic-config-value 'component.callbacks.allowedAddresses=[{"Pattern":"localhost:7243","AllowInsecure":true}]' &
114114
sleep 10s
115115
116-
- name: Run unit tests (Java 8)
116+
# Can't actually run tests against Java 8 because Mockito 5 requires Java 11+.
117+
# We therefore have to rely on the fact that the code has been compiled with
118+
# `-release 8` which guarantees that the code is technically (bytecode + API
119+
# usage) compatible with Java 8.
120+
- name: Run unit tests (Java 11)
117121
env:
118122
USER: unittest
119123
TEMPORAL_SERVICE_ADDRESS: localhost:7233
120124
USE_DOCKER_SERVICE: true
121-
run: ./gradlew --no-daemon test -x spotlessCheck -x spotlessApply -x spotlessJava -PtestJavaVersion=8
125+
run: ./gradlew --no-daemon test -x spotlessCheck -x spotlessApply -x spotlessJava -PtestJavaVersion=11
122126

123127
- name: Run Jackson 3 converter tests (Java 17)
124128
env:

0 commit comments

Comments
 (0)