Skip to content

Commit

Permalink
Drop deprecated SubProcess apply overload
Browse files Browse the repository at this point in the history
  • Loading branch information
dwijnand committed Apr 11, 2017
1 parent 9f688be commit cef287b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
4 changes: 0 additions & 4 deletions main-actions/src/main/scala/sbt/Tests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,6 @@ object Tests {

/** Configures a group of tests to be forked in a new JVM with forking options specified by `config`. */
final case class SubProcess(config: ForkOptions) extends TestRunPolicy
object SubProcess {
@deprecated("Construct SubProcess with a ForkOptions argument.", "0.13.0")
def apply(javaOptions: Seq[String]): SubProcess = SubProcess(ForkOptions(runJVMOptions = javaOptions))
}

/** A named group of tests configured to run in the same JVM or be forked. */
final case class Group(name: String, tests: Seq[TestDefinition], runPolicy: TestRunPolicy)
Expand Down
3 changes: 2 additions & 1 deletion sbt/src/sbt-test/tests/empty/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ testGrouping := {
new Tests.Group(
name = test.name,
tests = Seq(test),
runPolicy = Tests.SubProcess(javaOptions = Seq.empty[String]))
runPolicy = Tests.SubProcess(ForkOptions(runJVMOptions = Seq.empty[String]))
)
}
}
6 changes: 5 additions & 1 deletion sbt/src/sbt-test/tests/fork/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,11 @@ lazy val root = (project in file(".")).
val tests = (definedTests in Test).value
assert(tests.size == 3)
for (idx <- 0 until groups) yield
new Group(groupId(idx), tests, SubProcess(Seq("-Dgroup.prefix=" + groupPrefix(idx))))
new Group(
groupId(idx),
tests,
SubProcess(ForkOptions(runJVMOptions = Seq("-Dgroup.prefix=" + groupPrefix(idx))))
)
},
check := {
val files =
Expand Down

0 comments on commit cef287b

Please sign in to comment.