dotty phase 2: scalafix ExplicitNonNullaryApply (#28949)
* scalafix ExplicitNonNullaryApply prepare + Temporarily use com.sandinh:sbt-scalafix because scalacenter/scalafix#1098 + Add ExplicitNonNullaryApply rule to .scalafix.conf + Manually fix a NonNullaryApply case in DeathWatchSpec that cause `fixall` fail because ExplicitNonNullaryApply rule incorrectly rewrite `context unbecome` to `context unbecome()` instead of `context.unbecome()` * scalafix ExplicitNonNullaryApply fix by enabling only ExplicitNonNullaryApply rule in .scalafix.conf then: ``` % sbt -Dakka.build.scalaVersion=2.13.1 > fixall ``` * scalafmtAll * Revert to ch.epfl.scala:sbt-scalafix Co-authored-by: Bùi Việt Thành <thanhbv@sandinh.net>
This commit is contained in:
parent
4ba835d328
commit
ea7205eaf7
266 changed files with 929 additions and 919 deletions
|
|
@ -36,7 +36,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => prefix)
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 2)
|
||||
suffixF.futureValue should ===(2 until 10)
|
||||
|
|
@ -48,7 +48,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => prefix)
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 10)
|
||||
suffixF.futureValue should be(empty)
|
||||
|
|
@ -60,7 +60,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => prefix)
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 10)
|
||||
suffixF.futureValue should be(empty)
|
||||
|
|
@ -73,7 +73,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
}(Keep.right)
|
||||
.take(10)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 10)
|
||||
suffixF.futureValue should ===(10 until 20)
|
||||
|
|
@ -85,7 +85,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
throw TE(s"I hate mondays! (${prefix.size})")
|
||||
}(Keep.right)
|
||||
.to(Sink.ignore)
|
||||
.run
|
||||
.run()
|
||||
|
||||
val ex = suffixF.failed.futureValue
|
||||
ex.getCause should not be null
|
||||
|
|
@ -101,7 +101,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
}
|
||||
}(Keep.right)
|
||||
.toMat(Sink.ignore)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
prefixF.futureValue should ===(0 until 10)
|
||||
val ex = suffixF.failed.futureValue
|
||||
ex should ===(TE("don't like 15 either!"))
|
||||
|
|
@ -182,7 +182,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => prefix).filter(_ => false)
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 4)
|
||||
suffixF.futureValue should be(empty)
|
||||
|
|
@ -198,7 +198,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => prefix).take(0)
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 4)
|
||||
suffixF.futureValue should be(empty)
|
||||
|
|
@ -210,7 +210,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => prefix).take(0).concat(Source(11 to 12))
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.futureValue should ===(0 until 4)
|
||||
suffixF.futureValue should ===(11 :: 12 :: Nil)
|
||||
|
|
@ -222,7 +222,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
Flow[Int].mapMaterializedValue(_ => throw TE(s"boom-bada-bang (${prefix.size})"))
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
prefixF.failed.futureValue should be(a[NeverMaterializedException])
|
||||
prefixF.failed.futureValue.getCause should ===(TE("boom-bada-bang (4)"))
|
||||
|
|
@ -239,7 +239,7 @@ class FlowFlatMapPrefixSpec extends StreamSpec {
|
|||
}(Keep.both)
|
||||
}(Keep.right)
|
||||
.toMat(Sink.seq)(Keep.both)
|
||||
.run
|
||||
.run()
|
||||
|
||||
suffixF.futureValue should be(empty)
|
||||
val (prefix, suffix) = prefixAndTailF.futureValue
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue