Skip to content

Commit

Permalink
x
Browse files Browse the repository at this point in the history
  • Loading branch information
He-Pin committed Jan 26, 2024
1 parent ebe2304 commit 844fa79
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions project/Jdk9.scala
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@
* Copyright (C) 2017-2022 Lightbend Inc. <https://www.lightbend.com>
*/

import sbt._
import sbt.Keys._
import JdkOptions.isJdk8
import sbt.*
import sbt.Keys.*

object Jdk9 extends AutoPlugin {
import JdkOptions.notOnJdk8
Expand Down Expand Up @@ -57,10 +58,18 @@ object Jdk9 extends AutoPlugin {
// Compile / fullClasspath ++= (CompileJdk9 / exportedProducts).value)
Compile / dependencyClasspathAsJars ++= notOnJdk8((CompileJdk9 / exportedProducts).value))

lazy val testSettings = Seq((Test / test) := {
(Test / test).value
(TestJdk9 / test).value
})
lazy val testSettings = Seq(
(Test / test) := Def.taskDyn {
if (isJdk8) {
Def.task {
(Test / test).value
}
} else {
Def.task {
(TestJdk9 / test).value
}
}
}.value)

override lazy val trigger = noTrigger
override lazy val projectConfigurations = Seq(CompileJdk9)
Expand Down

0 comments on commit 844fa79

Please sign in to comment.