From be441e786ead9cc251418856189751b3e51d325e Mon Sep 17 00:00:00 2001 From: Guillaume Martres Date: Sat, 15 Sep 2018 03:49:33 +0200 Subject: Remove useless type parameters for {Test,}Evaluator (#416) * Remove useless type parameters for {Test,}Evaluator * Update Evaluator.scala --- contrib/buildinfo/test/src/mill/contrib/BuildInfoTests.scala | 6 +++--- .../test/src/mill/contrib/scalapblib/TutorialTests.scala | 7 +++---- contrib/twirllib/test/src/mill/twirllib/HelloWorldTests.scala | 6 +++--- 3 files changed, 9 insertions(+), 10 deletions(-) (limited to 'contrib') diff --git a/contrib/buildinfo/test/src/mill/contrib/BuildInfoTests.scala b/contrib/buildinfo/test/src/mill/contrib/BuildInfoTests.scala index 9e1549de..e2147bac 100644 --- a/contrib/buildinfo/test/src/mill/contrib/BuildInfoTests.scala +++ b/contrib/buildinfo/test/src/mill/contrib/BuildInfoTests.scala @@ -45,9 +45,9 @@ object BuildInfoTests extends TestSuite { val resourcePath = pwd / 'contrib / 'buildinfo / 'test / 'resources / "buildinfo" - def workspaceTest[T, M <: TestUtil.BaseModule](m: M, resourcePath: Path = resourcePath) - (t: TestEvaluator[M] => T) - (implicit tp: TestPath): T = { + def workspaceTest[T](m: TestUtil.BaseModule, resourcePath: Path = resourcePath) + (t: TestEvaluator => T) + (implicit tp: TestPath): T = { val eval = new TestEvaluator(m) rm(m.millSourcePath) rm(eval.outPath) diff --git a/contrib/scalapblib/test/src/mill/contrib/scalapblib/TutorialTests.scala b/contrib/scalapblib/test/src/mill/contrib/scalapblib/TutorialTests.scala index f88d3a5f..8542d60e 100644 --- a/contrib/scalapblib/test/src/mill/contrib/scalapblib/TutorialTests.scala +++ b/contrib/scalapblib/test/src/mill/contrib/scalapblib/TutorialTests.scala @@ -27,12 +27,11 @@ object TutorialTests extends TestSuite { val resourcePath: Path = pwd / 'contrib / 'scalapblib / 'test / 'protobuf / 'tutorial - def protobufOutPath[M <: TestUtil.BaseModule](eval: TestEvaluator[M]): Path = + def protobufOutPath(eval: TestEvaluator): Path = eval.outPath / 'core / 'compileScalaPB / 'dest / 'com / 'example / 'tutorial - def workspaceTest[T, M <: TestUtil.BaseModule](m: M) - (t: TestEvaluator[M] => T) - (implicit tp: TestPath): T = { + def workspaceTest[T](m: TestUtil.BaseModule)(t: TestEvaluator => T) + (implicit tp: TestPath): T = { val eval = new TestEvaluator(m) rm(m.millSourcePath) println(m.millSourcePath) diff --git a/contrib/twirllib/test/src/mill/twirllib/HelloWorldTests.scala b/contrib/twirllib/test/src/mill/twirllib/HelloWorldTests.scala index 01576975..8ef6ee3e 100644 --- a/contrib/twirllib/test/src/mill/twirllib/HelloWorldTests.scala +++ b/contrib/twirllib/test/src/mill/twirllib/HelloWorldTests.scala @@ -24,9 +24,9 @@ object HelloWorldTests extends TestSuite { val resourcePath: Path = pwd / 'contrib / 'twirllib / 'test / 'resources / "hello-world" - def workspaceTest[T, M <: TestUtil.BaseModule](m: M, resourcePath: Path = resourcePath) - (t: TestEvaluator[M] => T) - (implicit tp: TestPath): T = { + def workspaceTest[T](m: TestUtil.BaseModule, resourcePath: Path = resourcePath) + (t: TestEvaluator => T) + (implicit tp: TestPath): T = { val eval = new TestEvaluator(m) rm(m.millSourcePath) rm(eval.outPath) -- cgit v1.2.3