This repository was archived by the owner on Sep 8, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +20
-2
lines changed
src/main/scala/scala/tools/partest/nest Expand file tree Collapse file tree 2 files changed +20
-2
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ organization := "org.scala-lang"
77
88name := " scala-partest"
99
10- version := " 1.0"
10+ version := " 1.0-RC1 "
1111
1212scalaBinaryVersion := " 2.11.0-M4"
1313
@@ -27,3 +27,14 @@ libraryDependencies += "org.scalacheck" %% "scalacheck" % "1.
2727
2828libraryDependencies += " org.scala-sbt" % " test-interface" % " 1.0"
2929
30+ resourceGenerators in Compile <+= Def .task {
31+ val props = new java.util.Properties
32+ props.put(" version.number" , version.value)
33+ val file = (resourceManaged in Compile ).value / " partest.properties"
34+ IO .write(props, null , file)
35+ Seq (file)
36+ }
37+
38+ mappings in (Compile , packageBin) += {
39+ (baseDirectory.value / " partest.properties" ) -> " partest.properties"
40+ }
Original file line number Diff line number Diff line change @@ -721,6 +721,12 @@ class Runner(val testFile: File, val suiteRunner: SuiteRunner) {
721721
722722}
723723
724+ /** Loads `library.properties` from the jar. */
725+ object Properties extends scala.util.PropertiesTrait {
726+ protected def propCategory = " partest"
727+ protected def pickJarBasedOn = classOf [SuiteRunner ]
728+ }
729+
724730/** Extended by Ant- and ConsoleRunner for running a set of tests. */
725731class SuiteRunner (
726732 val testSourcePath : String ,
@@ -744,7 +750,8 @@ class SuiteRunner(
744750 val vmBin = javaHome + fileSeparator + " bin"
745751 val vmName = " %s (build %s, %s)" .format(javaVmName, javaVmVersion, javaVmInfo)
746752
747- s """ |Compiler under test: ${relativize(fileManager.compilerUnderTest.getAbsolutePath)}
753+ s """ |Partest version: ${Properties .versionNumberString}
754+ |Compiler under test: ${relativize(fileManager.compilerUnderTest.getAbsolutePath)}
748755 |Scala version is: $versionMsg
749756 |Scalac options are: ${scalacExtraArgs.mkString(" " )}
750757 |Compilation Path: ${relativize(joinPaths(fileManager.testClassPath))}
You can’t perform that action at this time.
0 commit comments