我的sbt文件中有以下代码需要更改,但是我不了解mapR函数,它等于map吗? 如果我在map case语句中有内容,该如何更改? 这是我的代码:
test := ((test, testCleanup) mapR {
case (Inc(fail: Incomplete), Value(cleanup)) =>
cleanup()
throw Incomplete(None, message = Some("tests failed"), causes = Seq(fail))
case (_, Value(cleanup)) =>
cleanup()
case _ =>
sys error "test cleanup impossible"
}
执行sbt时,出现以下警告:
method t2ToTable2 in object Scoped is deprecated: The sbt 0.10 style DSL is deprecated: '(k1, k2) map { (x, y) => ... }' should now be '{ val x = k1.value; val y = k2.value }'.
[warn] See http://www.scala-sbt.org/0.13/docs/Migrating-from-sbt-012x.html
[warn] test := { ((test, testCleanup) mapR {