Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions test/dotty/partest/DPConfig.scala
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ import scala.collection.JavaConversions._
import scala.reflect.io.Path
import java.io.File

import scala.tools.partest.PartestDefaults


/** Dotty Partest runs all tests in the provided testDirs located under
* testRoot. There can be several directories with pos resp. neg tests, as
Expand All @@ -15,6 +17,12 @@ import java.io.File
* otherwise pos/__defaultFlags.flags are used if the file exists).
*/
object DPConfig {
/** Options used for _running_ the run tests.
* Note that this is different from the options used when _compiling_ tests,
* those are determined by the sbt configuration.
*/
val runJVMOpts = s"-Xms64M -Xmx1024M ${PartestDefaults.javaOpts}"

val testRoot = (Path(".") / Path("tests") / Path("partest-generated")).toString
val genLog = Path(testRoot) / Path("gen.log")

Expand Down
5 changes: 3 additions & 2 deletions test/dotty/partest/DPConsoleRunner.scala
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,9 @@ class DPSuiteRunner(testSourcePath: String, // relative path, like "files", or "
consoleArgs: String,
javaCmdPath: String = PartestDefaults.javaCmd,
javacCmdPath: String = PartestDefaults.javacCmd,
scalacExtraArgs: Seq[String] = Seq.empty)
extends SuiteRunner(testSourcePath, fileManager, updateCheck, failed, javaCmdPath, javacCmdPath, scalacExtraArgs) {
scalacExtraArgs: Seq[String] = Seq.empty,
javaOpts: String = DPConfig.runJVMOpts)
extends SuiteRunner(testSourcePath, fileManager, updateCheck, failed, javaCmdPath, javacCmdPath, scalacExtraArgs, javaOpts) {

if (!DPConfig.runTestsInParallel)
sys.props("partest.threads") = "1"
Expand Down