diff --git a/.github/workflows/run-codebuild-ci.yml b/.github/workflows/run-codebuild-ci.yml
index d581ce27..d777a0f6 100644
--- a/.github/workflows/run-codebuild-ci.yml
+++ b/.github/workflows/run-codebuild-ci.yml
@@ -36,7 +36,7 @@ jobs:
platform:
- distribution: corretto
image: "aws/codebuild/standard:7.0"
- version: [ 8, 11 ]
+ version: [ 8, 11, 17, 21 ]
steps:
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v3
@@ -49,5 +49,9 @@ jobs:
timeout-minutes: 60
with:
project-name: java-ddb-ec
- buildspec-override: codebuild/${{ matrix.platform.distribution }}${{ matrix.version }}.yml
+ buildspec-override: codebuild/corretto.yml
image-override: ${{ matrix.platform.image }}
+ env-vars-for-codebuild: |
+ JAVA_VERSION
+ env:
+ JAVA_VERSION: ${{ matrix.version }}
diff --git a/codebuild/corretto11.yml b/codebuild/corretto.yml
similarity index 74%
rename from codebuild/corretto11.yml
rename to codebuild/corretto.yml
index 6c394676..547d0640 100644
--- a/codebuild/corretto11.yml
+++ b/codebuild/corretto.yml
@@ -3,7 +3,7 @@ version: 0.2
phases:
install:
runtime-versions:
- java: corretto11
+ java: corretto$JAVA_VERSION
build:
commands:
- mvn install
diff --git a/codebuild/corretto8.yml b/codebuild/corretto8.yml
deleted file mode 100644
index 3c14db6e..00000000
--- a/codebuild/corretto8.yml
+++ /dev/null
@@ -1,9 +0,0 @@
-version: 0.2
-
-phases:
- install:
- runtime-versions:
- java: corretto8
- build:
- commands:
- - mvn install
diff --git a/codebuild/openjdk11.yml b/codebuild/openjdk11.yml
deleted file mode 100644
index 9e184d25..00000000
--- a/codebuild/openjdk11.yml
+++ /dev/null
@@ -1,9 +0,0 @@
-version: 0.2
-
-phases:
- install:
- runtime-versions:
- java: openjdk11
- build:
- commands:
- - mvn install
diff --git a/codebuild/openjdk8.yml b/codebuild/openjdk8.yml
deleted file mode 100644
index 2157de50..00000000
--- a/codebuild/openjdk8.yml
+++ /dev/null
@@ -1,9 +0,0 @@
-version: 0.2
-
-phases:
- install:
- runtime-versions:
- java: openjdk8
- build:
- commands:
- - mvn install
diff --git a/sdk1/pom.xml b/sdk1/pom.xml
index 26db9089..d6e81977 100644
--- a/sdk1/pom.xml
+++ b/sdk1/pom.xml
@@ -153,6 +153,12 @@
pom
import
+
+ org.mockito
+ mockito-core
+ 4.11.0
+ test
+
@@ -260,6 +266,19 @@
4.13.2
test
+
+
+ org.mockito
+ mockito-core
+ test
+
+
+
+ org.mockito
+ mockito-inline
+ 4.11.0
+ test
+
@@ -333,6 +352,7 @@
${maven-surefire-plugin.version}
false
+ -Dnet.bytebuddy.experimental=true
**/Test*.java
**/*Test.java
diff --git a/sdk1/src/test/java/com/amazonaws/services/dynamodbv2/datamodeling/internal/TTLCacheTest.java b/sdk1/src/test/java/com/amazonaws/services/dynamodbv2/datamodeling/internal/TTLCacheTest.java
index 5bb7bcb7..2dc3ea88 100644
--- a/sdk1/src/test/java/com/amazonaws/services/dynamodbv2/datamodeling/internal/TTLCacheTest.java
+++ b/sdk1/src/test/java/com/amazonaws/services/dynamodbv2/datamodeling/internal/TTLCacheTest.java
@@ -2,7 +2,7 @@
// SPDX-License-Identifier: Apache-2.0
package com.amazonaws.services.dynamodbv2.datamodeling.internal;
-import static org.mockito.Matchers.any;
+import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.spy;
import static org.mockito.Mockito.times;