summaryrefslogtreecommitdiff
path: root/build.sbt
diff options
context:
space:
mode:
authorSeth Tisue <seth@tisue.net>2017-01-23 14:35:47 -0800
committerSeth Tisue <seth@tisue.net>2017-01-27 09:29:53 -0800
commit4386b948a0b597cc78e4f3b22b51e0588a5b6d60 (patch)
treeeca8cea41d110d8b14d27a83ae06a90e966f9621 /build.sbt
parent27c10db549e6f43571663d0162b58fc04fbb34bf (diff)
downloadscala-4386b948a0b597cc78e4f3b22b51e0588a5b6d60.tar.gz
scala-4386b948a0b597cc78e4f3b22b51e0588a5b6d60.tar.bz2
scala-4386b948a0b597cc78e4f3b22b51e0588a5b6d60.zip
run ScalaCheck tests directly, not through partest
ScalaCheck ever being under partest in the first place is ancient history, from back in the Ant build days (shudder) ScalaCheck support was removed from partest 1.1.0, which we already upgraded to in a recent commit also upgrades ScalaCheck from 1.11.6 to 1.13.4, since we might as well. no source changes were necessary.
Diffstat (limited to 'build.sbt')
-rw-r--r--build.sbt27
1 files changed, 20 insertions, 7 deletions
diff --git a/build.sbt b/build.sbt
index 268b9c51d7..9f6da2d17d 100644
--- a/build.sbt
+++ b/build.sbt
@@ -3,7 +3,7 @@
*
* What you see below is very much work-in-progress. The following features are implemented:
* - Compiling all classses for the compiler and library ("compile" in the respective subprojects)
- * - Running JUnit tests ("test") and partest ("test/it:test")
+ * - Running JUnit ("junit/test"), ScalaCheck ("scalacheck/test"), and partest ("test/it:test") tests
* - Creating build/quick with all compiled classes and launcher scripts ("dist/mkQuick")
* - Creating build/pack with all JARs and launcher scripts ("dist/mkPack")
* - Building all scaladoc sets ("doc")
@@ -39,11 +39,11 @@ val scalaSwingDep = scalaDep("org.scala-lang.modules", "scala-swi
val scalaXmlDep = scalaDep("org.scala-lang.modules", "scala-xml")
val scalaParserCombinatorsDep = scalaDep("org.scala-lang.modules", "scala-parser-combinators")
val partestDep = scalaDep("org.scala-lang.modules", "scala-partest", versionProp = "partest")
-val scalacheckDep = scalaDep("org.scalacheck", "scalacheck", scope = "it")
// Non-Scala dependencies:
val junitDep = "junit" % "junit" % "4.11"
val junitInterfaceDep = "com.novocode" % "junit-interface" % "0.11" % "test"
+val scalacheckDep = "org.scalacheck" % "scalacheck_2.12" % "1.13.4" % "test"
val jolDep = "org.openjdk.jol" % "jol-core" % "0.5"
val asmDep = "org.scala-lang.modules" % "scala-asm" % versionProps("scala-asm.version")
val jlineDep = "jline" % "jline" % versionProps("jline.version")
@@ -567,7 +567,20 @@ lazy val junit = project.in(file("test") / "junit")
javaOptions in Test += "-Xss1M",
libraryDependencies ++= Seq(junitDep, junitInterfaceDep, jolDep),
testOptions += Tests.Argument(TestFrameworks.JUnit, "-a", "-v"),
- // testFrameworks -= new TestFramework("org.scalacheck.ScalaCheckFramework"),
+ unmanagedSourceDirectories in Compile := Nil,
+ unmanagedSourceDirectories in Test := List(baseDirectory.value)
+ )
+
+lazy val scalacheck = project.in(file("test") / "scalacheck")
+ .dependsOn(library, reflect, compiler, scaladoc)
+ .settings(clearSourceAndResourceDirectories)
+ .settings(commonSettings)
+ .settings(disableDocs)
+ .settings(disablePublishing)
+ .settings(
+ fork in Test := true,
+ javaOptions in Test += "-Xss1M",
+ libraryDependencies ++= Seq(scalacheckDep),
unmanagedSourceDirectories in Compile := Nil,
unmanagedSourceDirectories in Test := List(baseDirectory.value)
)
@@ -647,7 +660,7 @@ lazy val test = project
.settings(disablePublishing)
.settings(Defaults.itSettings)
.settings(
- libraryDependencies ++= Seq(asmDep, partestDep, scalaXmlDep, scalacheckDep),
+ libraryDependencies ++= Seq(asmDep, partestDep, scalaXmlDep),
libraryDependencies ++= {
// Resolve the JARs for all test/files/lib/*.jar.desired.sha1 files through Ivy
val baseDir = (baseDirectory in ThisBuild).value
@@ -664,7 +677,6 @@ lazy val test = project
fork in IntegrationTest := true,
javaOptions in IntegrationTest += "-Xmx2G",
testFrameworks += new TestFramework("scala.tools.partest.sbt.Framework"),
- // testFrameworks -= new TestFramework("org.scalacheck.ScalaCheckFramework"),
testOptions in IntegrationTest += Tests.Argument("-Dpartest.java_opts=-Xmx1024M -Xms64M"),
testOptions in IntegrationTest += Tests.Argument("-Dpartest.scalac_opts=" + (scalacOptions in Compile).value.mkString(" ")),
testOptions in IntegrationTest += Tests.Setup { () =>
@@ -796,9 +808,10 @@ lazy val root: Project = (project in file("."))
testAll := {
val results = ScriptCommands.sequence[Result[Unit]](List(
(Keys.test in Test in junit).result,
+ (Keys.test in Test in scalacheck).result,
(testOnly in IntegrationTest in testP).toTask(" -- run").result,
(testOnly in IntegrationTest in testP).toTask(" -- pos neg jvm").result,
- (testOnly in IntegrationTest in testP).toTask(" -- res scalap specialized scalacheck").result,
+ (testOnly in IntegrationTest in testP).toTask(" -- res scalap specialized").result,
(testOnly in IntegrationTest in testP).toTask(" -- instrumented presentation").result,
(testOnly in IntegrationTest in testP).toTask(" -- --srcpath scaladoc").result,
(Keys.test in Test in osgiTestFelix).result,
@@ -817,7 +830,7 @@ lazy val root: Project = (project in file("."))
"junit/test",
"partest run",
"partest pos neg jvm",
- "partest res scalap specialized scalacheck",
+ "partest res scalap specialized",
"partest instrumented presentation",
"partest --srcpath scaladoc",
"osgiTestFelix/test",