Skip to content

Commit

Permalink
Switch to latest Scala-Test version
Browse files Browse the repository at this point in the history
  • Loading branch information
JanBessai committed Feb 6, 2020
1 parent 27e46f5 commit 7729d48
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 16 deletions.
11 changes: 5 additions & 6 deletions build.sbt
Expand Up @@ -3,8 +3,8 @@ import sbt.{Credentials, Developer, ScmInfo}
lazy val commonSettings = Seq(
organization := "org.combinators",

scalaVersion := "2.12.9",
crossScalaVersions := Seq("2.11.12", "2.12.9", scalaVersion.value),
scalaVersion := "2.13.1",
crossScalaVersions := Seq("2.11.12", "2.12.10", scalaVersion.value),

resolvers ++= Seq(
Resolver.sonatypeRepo("releases"),
Expand All @@ -28,10 +28,9 @@ lazy val root = Project(id = "shapeless-feat", base = file(".")).
settings(
moduleName := "shapeless-feat",
libraryDependencies += "com.chuusai" %% "shapeless" % "2.3.3",
libraryDependencies += "org.typelevel" %% "cats-core" % "2.0.0",
libraryDependencies += "org.typelevel" %% "cats-free" % "2.0.0",
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.8" % "test",
libraryDependencies += "org.scalacheck" %% "scalacheck" % "1.14.0" % "test",
libraryDependencies += "org.scalatest" %% "scalatest" % "3.1.0" % "test",
libraryDependencies += "org.scalatestplus" %% "scalacheck-1-14" % "3.1.0.1" % "test",
libraryDependencies += "org.scalacheck" %% "scalacheck" % "1.14.1" % "test",
unmanagedSourceDirectories in Compile += {
val sourceDir = (sourceDirectory in Compile).value
CrossVersion.partialVersion(scalaVersion.value) match {
Expand Down
8 changes: 5 additions & 3 deletions src/test/scala/shapeless/feat/AlgebraTest.scala
Expand Up @@ -19,10 +19,12 @@ import scala.util.Try
import org.scalatest._
import org.scalacheck.Gen
import org.scalacheck.Arbitrary
import org.scalatest.prop.GeneratorDrivenPropertyChecks
//import org.scalatest.prop.GeneratorDrivenPropertyChecks
import org.scalatestplus.scalacheck.ScalaCheckDrivenPropertyChecks
import org.scalatest.freespec.AnyFreeSpec
import org.scalatest.matchers.should.Matchers

class AlgebraTest extends FreeSpec with ScalaCheckDrivenPropertyChecks with Matchers with MatcherUtil {
class AlgebraTest extends AnyFreeSpec with ScalaCheckDrivenPropertyChecks with Matchers with MatcherUtil {
import EnumerableInstances._

implicit val smallBigInt = Arbitrary(Gen.choose[Int](Int.MinValue, generatorDrivenConfig.sizeRange).map(BigInt(_)))
Expand Down Expand Up @@ -88,4 +90,4 @@ class AlgebraTest extends FreeSpec with ScalaCheckDrivenPropertyChecks with Matc
}
}

}
}
7 changes: 4 additions & 3 deletions src/test/scala/shapeless/feat/KnownInstanceTest.scala
Expand Up @@ -16,10 +16,11 @@

package shapeless.feat

import org.scalatest._
import org.scalatestplus.scalacheck.ScalaCheckDrivenPropertyChecks
import org.scalatest.freespec.AnyFreeSpec
import org.scalatest.matchers.should.Matchers

class KnownInstanceTest extends FreeSpec with ScalaCheckDrivenPropertyChecks with Matchers {
class KnownInstanceTest extends AnyFreeSpec with ScalaCheckDrivenPropertyChecks with Matchers {
import enumerables._
import ArbitraryInstances._
import EnumerableInstances._
Expand Down Expand Up @@ -80,4 +81,4 @@ class KnownInstanceTest extends FreeSpec with ScalaCheckDrivenPropertyChecks wit
}

}
}
}
5 changes: 3 additions & 2 deletions src/test/scala/shapeless/feat/MatcherUtil.scala
Expand Up @@ -16,7 +16,8 @@

package shapeless.feat
import org.scalatest._
import org.scalatest.matchers._
import org.scalatest.matchers.should.Matchers
import org.scalatest.matchers.Matcher

trait MatcherUtil { self : Matchers =>
def equalOrExceptAtIndex[T](i: BigInt)(y: Enumeration[T]) = new Matcher[Enumeration[T]] {
Expand All @@ -31,4 +32,4 @@ trait MatcherUtil { self : Matchers =>
}
}
}
}
}
4 changes: 3 additions & 1 deletion src/test/scala/shapeless/feat/PerformanceTest.scala
Expand Up @@ -20,9 +20,11 @@ import org.scalatest._
import org.scalatest.concurrent._
import org.scalatest.time.SpanSugar._
import org.scalatestplus.scalacheck.ScalaCheckDrivenPropertyChecks
import org.scalatest.freespec.AnyFreeSpec
import org.scalatest.matchers.should.Matchers


class PerformanceTest extends FreeSpec with ScalaCheckDrivenPropertyChecks with Matchers with MatcherUtil with TimeLimits {
class PerformanceTest extends AnyFreeSpec with ScalaCheckDrivenPropertyChecks with Matchers with MatcherUtil with TimeLimits {
import EnumerableInstances._

"Checking performance" - {
Expand Down
4 changes: 3 additions & 1 deletion src/test/scala/shapeless/feat/PrimitiveTest.scala
Expand Up @@ -18,8 +18,10 @@ package shapeless.feat

import org.scalatest._
import org.scalatestplus.scalacheck.ScalaCheckDrivenPropertyChecks
import org.scalatest.freespec.AnyFreeSpec
import org.scalatest.matchers.should.Matchers

class PrimitiveTest extends FreeSpec with ScalaCheckDrivenPropertyChecks with Matchers {
class PrimitiveTest extends AnyFreeSpec with ScalaCheckDrivenPropertyChecks with Matchers {

"Enumerating Booleans" - {
"checking true, false" in {
Expand Down

0 comments on commit 7729d48

Please sign in to comment.