diff --git a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt index 19d921ef1..099cd9f71 100644 --- a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt +++ b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt @@ -1,19 +1,16 @@ -lazy val dottyVersion = dottyLatestNightlyBuild +// hardcode dottyVersion to make test deterministic +lazy val dottyVersion = "0.8.0-bin-20180424-e77604d-NIGHTLY" -lazy val pluginSetting = Seq( - name := "dividezero", - version := "0.0.1", - organization := "ch.epfl.lamp", - scalaVersion := dottyVersion, - - libraryDependencies ++= Seq( - "ch.epfl.lamp" %% "dotty" % "provided" +lazy val plugin = (project in file("plugin")) + .settings( + name := "dividezero", + version := "0.0.1", + organization := "ch.epfl.lamp", + scalaVersion := dottyVersion, ) -) -lazy val plugin = (project in file("plugin")).settings(pluginSetting: _*) - -lazy val app = (project in file(".")).settings( - scalaVersion := dottyVersion, - libraryDependencies += compilerPlugin("ch.epfl.lamp" %% "dividezero" % "0.0.1") -) +lazy val app = (project in file(".")) + .settings( + scalaVersion := dottyVersion, + libraryDependencies += compilerPlugin("ch.epfl.lamp" %% "dividezero" % "0.0.1"), + ) diff --git a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/plugin/DivideZero.scala b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/plugin/DivideZero.scala index 1dfe23cf5..c110a7cee 100644 --- a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/plugin/DivideZero.scala +++ b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/plugin/DivideZero.scala @@ -18,8 +18,8 @@ class DivideZero extends PluginPhase with StandardPlugin { val phaseName = name - override val runsAfter = Set(Pickler.phaseName) - override val runsBefore = Set(LinkAll.phaseName) + override val runsAfter = Set(Pickler.name) + override val runsBefore = Set(LinkAll.name) override def init(options: List[String]): List[PluginPhase] = this :: Nil