summaryrefslogtreecommitdiff
path: root/core/test
diff options
context:
space:
mode:
authorLi Haoyi <haoyi.sg@gmail.com>2018-01-23 21:41:28 -0800
committerLi Haoyi <haoyi.sg@gmail.com>2018-01-23 21:59:55 -0800
commit8554e1cb9ab8787f402e86749ea18a15f24af00d (patch)
tree4fcdffc9cb16d95f7e43474b348f9704e6248be3 /core/test
parentc5b54b496af1a4aae2624c2f6d1e551b5026d54b (diff)
downloadmill-8554e1cb9ab8787f402e86749ea18a15f24af00d.tar.gz
mill-8554e1cb9ab8787f402e86749ea18a15f24af00d.tar.bz2
mill-8554e1cb9ab8787f402e86749ea18a15f24af00d.zip
Make `T.worker`s compute their signature based on their inputs, rather than the hash of their output, to allow for returning functions/classloaders/subprocesses/etc. which do not hash reliably between process restarts
Diffstat (limited to 'core/test')
-rw-r--r--core/test/src/mill/eval/TaskTests.scala2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/test/src/mill/eval/TaskTests.scala b/core/test/src/mill/eval/TaskTests.scala
index 3c355fa4..3f265618 100644
--- a/core/test/src/mill/eval/TaskTests.scala
+++ b/core/test/src/mill/eval/TaskTests.scala
@@ -8,6 +8,8 @@ object TaskTests extends TestSuite{
val tests = Tests{
object build extends mill.util.TestUtil.BaseModule{
var count = 0
+ // Explicitly instantiate `Function1` objects to make sure we get
+ // different instances each time
def staticWorker = T.worker{
new Function1[Int, Int] {
def apply(v1: Int) = v1 + 1