diff --git a/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/AhcWSRequestSpec.scala b/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/AhcWSRequestSpec.scala index 2bb8f22e..45e4ebc4 100644 --- a/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/AhcWSRequestSpec.scala +++ b/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/AhcWSRequestSpec.scala @@ -104,9 +104,9 @@ class AhcWSRequestSpec extends Specification with AfterAll with DefaultBodyReada .withQueryStringParameters("play" -> "foo1") .addQueryStringParameters("play" -> "foo2") - newRequest.queryString.get("play") must beSome.which(_.contains("foo1")) - newRequest.queryString.get("play") must beSome.which(_.contains("foo2")) - newRequest.queryString.get("play") must beSome.which(_.size == 2) + newRequest.queryString.get("play") must beSome[Seq[String]].which(_.contains("foo1")) + newRequest.queryString.get("play") must beSome[Seq[String]].which(_.contains("foo2")) + newRequest.queryString.get("play") must beSome[Seq[String]].which(_.size == 2) } "support several query string values for a parameter" in { diff --git a/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/cache/AhcWSCacheSpec.scala b/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/cache/AhcWSCacheSpec.scala index 7224e69c..946708ce 100644 --- a/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/cache/AhcWSCacheSpec.scala +++ b/play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/cache/AhcWSCacheSpec.scala @@ -33,7 +33,7 @@ class AhcWSCacheSpec extends Specification { val actual = cache.calculateFreshnessFromHeuristic(request, response) - actual must beSome.which { case value => + actual must beSome[Seconds].which { case value => value must be_==(Seconds.seconds(360)) // 0.1 hours } } @@ -72,7 +72,7 @@ class AhcWSCacheSpec extends Specification { val actual = cache.calculateSecondaryKeys(request, response) - actual must beSome.which { d => + actual must beSome[Map[HeaderName, Seq[String]]].which { d => d must haveKey(HeaderName("Accept-Encoding")) d(HeaderName("Accept-Encoding")) must be_==(Seq("gzip")) } diff --git a/play-ws-standalone/src/test/scala/play/api/libs/ws/WSConfigParserSpec.scala b/play-ws-standalone/src/test/scala/play/api/libs/ws/WSConfigParserSpec.scala index 4b97bca3..7c71dc04 100644 --- a/play-ws-standalone/src/test/scala/play/api/libs/ws/WSConfigParserSpec.scala +++ b/play-ws-standalone/src/test/scala/play/api/libs/ws/WSConfigParserSpec.scala @@ -39,7 +39,7 @@ class WSConfigParserSpec extends Specification { // default: true actual.useProxyProperties must beFalse - actual.userAgent must beSome.which(_ must_== "FakeUserAgent") + actual.userAgent must beSome[String].which(_ must_== "FakeUserAgent") } } } diff --git a/project/Dependencies.scala b/project/Dependencies.scala index 04a96fd3..5ee84c9a 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -18,7 +18,7 @@ object Dependencies { val specsVersion = "4.19.2" val specsBuild = Seq( "specs2-core", - ).map("org.specs2" %% _ % specsVersion cross CrossVersion.for3Use2_13) + ).map("org.specs2" %% _ % specsVersion) val mockito = Seq("org.mockito" % "mockito-core" % "5.2.0")