From a0c18041b3e646d90d361b1a8d2048dcb16d3e97 Mon Sep 17 00:00:00 2001 From: Chua Chee Seng Date: Sat, 14 Oct 2023 10:22:39 +0800 Subject: [PATCH 1/3] Updated to use mockito 5.6.0, and added a note in README.md about the requirement for jdk11 for mockito 5. --- README.md | 9 ++++++--- build.sbt | 6 +++--- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index a63c926..70642b1 100644 --- a/README.md +++ b/README.md @@ -3,12 +3,12 @@ ScalaTest + Mockito provides integration support between ScalaTest and Mockito. **Usage** -To use it for ScalaTest 3.2.17 and Mockito 4.11.x: +To use it for ScalaTest 3.2.17 and Mockito 5.6.x: SBT: ``` -libraryDependencies += "org.scalatestplus" %% "mockito-4-11" % "3.2.17.0" % "test" +libraryDependencies += "org.scalatestplus" %% "mockito-5-6" % "3.2.17.0" % "test" ``` Maven: @@ -16,12 +16,15 @@ Maven: ``` org.scalatestplus - mockito-4-11_2.13 + mockito-5-6_3 3.2.17.0 test ``` +**Note** +Mockito 5.x requires JDK11+, if you are on JDK8, please use `mockito-4-11` instead. + **Publishing** Please use the following commands to publish to Sonatype: diff --git a/build.sbt b/build.sbt index c8423c5..a9697d6 100644 --- a/build.sbt +++ b/build.sbt @@ -1,7 +1,7 @@ import java.io.PrintWriter import scala.io.Source -name := "mockito-4.11" +name := "mockito-5.6" organization := "org.scalatestplus" @@ -30,10 +30,10 @@ developers := List( scalaVersion := "2.13.11" -crossScalaVersions := List("2.10.7", "2.11.12", "2.12.17", "2.13.11", "3.1.3") +crossScalaVersions := List("2.10.7", "2.11.12", "2.12.18", "2.13.11", "3.1.3") libraryDependencies ++= Seq( - "org.mockito" % "mockito-core" % "4.11.0", + "org.mockito" % "mockito-core" % "5.6.0", "org.scalatest" %% "scalatest-core" % "3.2.17", "org.scalatest" %% "scalatest-funsuite" % "3.2.17" % "test" ) From 02175aa8e11ad8c4629294665bed7a767c88453f Mon Sep 17 00:00:00 2001 From: Chua Chee Seng Date: Tue, 17 Oct 2023 08:36:50 +0800 Subject: [PATCH 2/3] Updated java version to 11 in ci.yml. --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e24adcf..ec8fcfb 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,6 +12,6 @@ jobs: uses: actions/setup-java@v3 with: distribution: temurin - java-version: 8 + java-version: 11 - name: Build and Test run: sbt -v +test From f4edd7858aa23a7df8f65c9faea0a58ea53a8b8e Mon Sep 17 00:00:00 2001 From: Chua Chee Seng Date: Fri, 15 Dec 2023 09:34:58 +0800 Subject: [PATCH 3/3] Bumped up to the latest Mockito 5.8. --- README.md | 6 +++--- build.sbt | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 70642b1..5d6be71 100644 --- a/README.md +++ b/README.md @@ -3,12 +3,12 @@ ScalaTest + Mockito provides integration support between ScalaTest and Mockito. **Usage** -To use it for ScalaTest 3.2.17 and Mockito 5.6.x: +To use it for ScalaTest 3.2.17 and Mockito 5.8.x: SBT: ``` -libraryDependencies += "org.scalatestplus" %% "mockito-5-6" % "3.2.17.0" % "test" +libraryDependencies += "org.scalatestplus" %% "mockito-5-8" % "3.2.17.0" % "test" ``` Maven: @@ -16,7 +16,7 @@ Maven: ``` org.scalatestplus - mockito-5-6_3 + mockito-5-8_3 3.2.17.0 test diff --git a/build.sbt b/build.sbt index a9697d6..b9290fe 100644 --- a/build.sbt +++ b/build.sbt @@ -1,7 +1,7 @@ import java.io.PrintWriter import scala.io.Source -name := "mockito-5.6" +name := "mockito-5.8" organization := "org.scalatestplus" @@ -28,12 +28,12 @@ developers := List( ) ) -scalaVersion := "2.13.11" +scalaVersion := "2.13.12" -crossScalaVersions := List("2.10.7", "2.11.12", "2.12.18", "2.13.11", "3.1.3") +crossScalaVersions := List("2.10.7", "2.11.12", "2.12.18", "2.13.12", "3.1.3") libraryDependencies ++= Seq( - "org.mockito" % "mockito-core" % "5.6.0", + "org.mockito" % "mockito-core" % "5.8.0", "org.scalatest" %% "scalatest-core" % "3.2.17", "org.scalatest" %% "scalatest-funsuite" % "3.2.17" % "test" )