From 94d1ddd9cf604bb1dc0b12f382e26ebe5d4d0af7 Mon Sep 17 00:00:00 2001 From: Adam Fraser Date: Fri, 8 Apr 2022 23:18:41 -0700 Subject: [PATCH] upgrade zio version (#614) --- build.sbt | 2 +- .../src/test/scala/zio/json/interop/refined/RefinedSpec.scala | 2 +- .../src/test/scala/zio/json/interop/scalaz/ScalazSpec.scala | 2 +- .../shared/src/test/scala/zio/json/DeriveSpec.scala | 2 +- .../src/test/scala/zio/json/yaml/YamlDecoderSpec.scala | 2 +- .../src/test/scala/zio/json/yaml/YamlEncoderSpec.scala | 2 +- zio-json/jvm/src/test/scala/zio/json/CarterSpec.scala | 2 +- .../src/test/scala/zio/json/internal/StringMatrixSpec.scala | 2 +- zio-json/shared/src/test/scala/zio/json/CodecSpec.scala | 2 +- zio-json/shared/src/test/scala/zio/json/DecoderSpec.scala | 2 +- zio-json/shared/src/test/scala/zio/json/EncoderSpec.scala | 2 +- zio-json/shared/src/test/scala/zio/json/Gens.scala | 4 +--- zio-json/shared/src/test/scala/zio/json/JavaTimeSpec.scala | 2 +- zio-json/shared/src/test/scala/zio/json/RoundTripSpec.scala | 2 +- zio-json/shared/src/test/scala/zio/json/ast/JsonSpec.scala | 2 +- 15 files changed, 15 insertions(+), 17 deletions(-) diff --git a/build.sbt b/build.sbt index 8190e11c6..0c2022222 100644 --- a/build.sbt +++ b/build.sbt @@ -35,7 +35,7 @@ addCommandAlias( addCommandAlias("testJS", "zioJsonJS/test") -val zioVersion = "2.0.0-RC4" +val zioVersion = "2.0.0-RC5" lazy val root = project .in(file(".")) diff --git a/zio-json-interop-refined/shared/src/test/scala/zio/json/interop/refined/RefinedSpec.scala b/zio-json-interop-refined/shared/src/test/scala/zio/json/interop/refined/RefinedSpec.scala index 4c5adec6a..775ef0e91 100644 --- a/zio-json-interop-refined/shared/src/test/scala/zio/json/interop/refined/RefinedSpec.scala +++ b/zio-json-interop-refined/shared/src/test/scala/zio/json/interop/refined/RefinedSpec.scala @@ -8,7 +8,7 @@ import zio.test.Assertion._ import zio.test._ object RefinedSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("Refined")( test("Refined") { assert("""{"name":""}""".fromJson[Person])(isLeft(equalTo(".name(Predicate isEmpty() did not fail.)"))) && diff --git a/zio-json-interop-scalaz7x/shared/src/test/scala/zio/json/interop/scalaz/ScalazSpec.scala b/zio-json-interop-scalaz7x/shared/src/test/scala/zio/json/interop/scalaz/ScalazSpec.scala index 7cef443a0..21c681cd3 100644 --- a/zio-json-interop-scalaz7x/shared/src/test/scala/zio/json/interop/scalaz/ScalazSpec.scala +++ b/zio-json-interop-scalaz7x/shared/src/test/scala/zio/json/interop/scalaz/ScalazSpec.scala @@ -7,7 +7,7 @@ import zio.test.Assertion._ import zio.test._ object ScalazSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("Scalaz")( test("scalaz.IList[A]") { assert(IList[Int]().toJson)(equalTo("[]")) && diff --git a/zio-json-macros/shared/src/test/scala/zio/json/DeriveSpec.scala b/zio-json-macros/shared/src/test/scala/zio/json/DeriveSpec.scala index ea573ba03..f7fe322e5 100644 --- a/zio-json-macros/shared/src/test/scala/zio/json/DeriveSpec.scala +++ b/zio-json-macros/shared/src/test/scala/zio/json/DeriveSpec.scala @@ -6,7 +6,7 @@ import zio.test._ object DeriveSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("DeriveCodec")( suite("Decoding")( test("parameterless products") { diff --git a/zio-json-yaml/src/test/scala/zio/json/yaml/YamlDecoderSpec.scala b/zio-json-yaml/src/test/scala/zio/json/yaml/YamlDecoderSpec.scala index e5060b1c0..962462e31 100644 --- a/zio-json-yaml/src/test/scala/zio/json/yaml/YamlDecoderSpec.scala +++ b/zio-json-yaml/src/test/scala/zio/json/yaml/YamlDecoderSpec.scala @@ -6,7 +6,7 @@ import zio.test._ object YamlDecoderSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("YamlDecoderSpec")( test("object root") { assert(ex1Yaml.fromYaml[Example])( diff --git a/zio-json-yaml/src/test/scala/zio/json/yaml/YamlEncoderSpec.scala b/zio-json-yaml/src/test/scala/zio/json/yaml/YamlEncoderSpec.scala index c9b2dd89c..6c53e3520 100644 --- a/zio-json-yaml/src/test/scala/zio/json/yaml/YamlEncoderSpec.scala +++ b/zio-json-yaml/src/test/scala/zio/json/yaml/YamlEncoderSpec.scala @@ -8,7 +8,7 @@ import zio.test._ object YamlEncoderSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("YamlEncoderSpec")( test("object root") { assert(ex1.toJsonAST.flatMap(_.toYaml(YamlOptions.default.copy(lineBreak = LineBreak.UNIX))))( diff --git a/zio-json/jvm/src/test/scala/zio/json/CarterSpec.scala b/zio-json/jvm/src/test/scala/zio/json/CarterSpec.scala index 37cb92b55..073e56273 100644 --- a/zio-json/jvm/src/test/scala/zio/json/CarterSpec.scala +++ b/zio-json/jvm/src/test/scala/zio/json/CarterSpec.scala @@ -27,7 +27,7 @@ object CarterSpec extends ZIOSpecDefault { implicit val decoder: JsonDecoder[Testing1] = DeriveJsonDecoder.gen } - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("Carter")( test("simple left") { type Data = Union[String, Int] diff --git a/zio-json/jvm/src/test/scala/zio/json/internal/StringMatrixSpec.scala b/zio-json/jvm/src/test/scala/zio/json/internal/StringMatrixSpec.scala index 8e95b8419..b2aa7754f 100644 --- a/zio-json/jvm/src/test/scala/zio/json/internal/StringMatrixSpec.scala +++ b/zio-json/jvm/src/test/scala/zio/json/internal/StringMatrixSpec.scala @@ -5,7 +5,7 @@ import zio.test.Assertion._ import zio.test._ object StringMatrixSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = suite("StringMatrix")( + val spec: ZSpec[Environment, Any] = suite("StringMatrix")( test("positive succeeds") { // Watch out: TestStrings were passed check(genTestStrings) { xs => diff --git a/zio-json/shared/src/test/scala/zio/json/CodecSpec.scala b/zio-json/shared/src/test/scala/zio/json/CodecSpec.scala index 472399b8d..ce6cfa84d 100644 --- a/zio-json/shared/src/test/scala/zio/json/CodecSpec.scala +++ b/zio-json/shared/src/test/scala/zio/json/CodecSpec.scala @@ -14,7 +14,7 @@ object CodecSpec extends ZIOSpecDefault { implicit lazy val codec: JsonCodec[RecursiveOption] = DeriveJsonCodec.gen[RecursiveOption] } - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("CodecSpec")( suite("Codec regressions")( test("option in recursive structure") { diff --git a/zio-json/shared/src/test/scala/zio/json/DecoderSpec.scala b/zio-json/shared/src/test/scala/zio/json/DecoderSpec.scala index ec6bc8b31..02cf4ba3a 100644 --- a/zio-json/shared/src/test/scala/zio/json/DecoderSpec.scala +++ b/zio-json/shared/src/test/scala/zio/json/DecoderSpec.scala @@ -12,7 +12,7 @@ import scala.collection.{ SortedMap, immutable, mutable } object DecoderSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("Decoder")( suite("fromJson")( test("BigDecimal") { diff --git a/zio-json/shared/src/test/scala/zio/json/EncoderSpec.scala b/zio-json/shared/src/test/scala/zio/json/EncoderSpec.scala index 40b20b4e9..52a123dec 100644 --- a/zio-json/shared/src/test/scala/zio/json/EncoderSpec.scala +++ b/zio-json/shared/src/test/scala/zio/json/EncoderSpec.scala @@ -12,7 +12,7 @@ import scala.collection.{ immutable, mutable } // zioJsonJVM/testOnly testzio.json.EncoderSpec object EncoderSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("Encoder")( suite("toJson")( suite("primitives")( diff --git a/zio-json/shared/src/test/scala/zio/json/Gens.scala b/zio-json/shared/src/test/scala/zio/json/Gens.scala index 5fdcd74f8..354140c64 100644 --- a/zio-json/shared/src/test/scala/zio/json/Gens.scala +++ b/zio-json/shared/src/test/scala/zio/json/Gens.scala @@ -1,9 +1,7 @@ package testzio.json -import zio.Random -import zio.test.{ Gen, Sized } +import zio.test.Gen -import java.math.BigInteger import java.time._ import scala.jdk.CollectionConverters._ import scala.util.Try diff --git a/zio-json/shared/src/test/scala/zio/json/JavaTimeSpec.scala b/zio-json/shared/src/test/scala/zio/json/JavaTimeSpec.scala index 3ac37347f..4f855292f 100644 --- a/zio-json/shared/src/test/scala/zio/json/JavaTimeSpec.scala +++ b/zio-json/shared/src/test/scala/zio/json/JavaTimeSpec.scala @@ -14,7 +14,7 @@ object JavaTimeSpec extends ZIOSpecDefault { private def equalToStringified(expected: String) = equalTo(s""""$expected"""") - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("java.time")( suite("Encoder")( test("DayOfWeek") { diff --git a/zio-json/shared/src/test/scala/zio/json/RoundTripSpec.scala b/zio-json/shared/src/test/scala/zio/json/RoundTripSpec.scala index c61009cbf..00ac86dc9 100644 --- a/zio-json/shared/src/test/scala/zio/json/RoundTripSpec.scala +++ b/zio-json/shared/src/test/scala/zio/json/RoundTripSpec.scala @@ -11,7 +11,7 @@ import java.time._ object RoundTripSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("RoundTrip")( test("booleans") { check(Gen.boolean)(assertRoundtrips[Boolean]) diff --git a/zio-json/shared/src/test/scala/zio/json/ast/JsonSpec.scala b/zio-json/shared/src/test/scala/zio/json/ast/JsonSpec.scala index 4f2a11d92..ded7033f2 100644 --- a/zio-json/shared/src/test/scala/zio/json/ast/JsonSpec.scala +++ b/zio-json/shared/src/test/scala/zio/json/ast/JsonSpec.scala @@ -5,7 +5,7 @@ import zio.test._ object JsonSpec extends ZIOSpecDefault { - val spec: ZSpec[Environment, Failure] = + val spec: ZSpec[Environment, Any] = suite("Json")( suite("equals")( test("mismatched Json subtypes") {