small test changes for Scala 2.12 (#21738)

This commit is contained in:
Patrik Nordwall 2016-10-28 14:59:08 +02:00 committed by Konrad Malawski
parent a0e2286b70
commit 1ff1f5edee
3 changed files with 6 additions and 4 deletions

View file

@ -11,7 +11,9 @@ import akka.testkit._
import scala.concurrent.duration._
import scala.concurrent.Await
class LocalDeathWatchSpec extends AkkaSpec with ImplicitSender with DefaultTimeout with DeathWatchSpec
class LocalDeathWatchSpec extends AkkaSpec("""
akka.actor.serialize-messages = off
""") with ImplicitSender with DefaultTimeout with DeathWatchSpec
object DeathWatchSpec {
def props(target: ActorRef, testActor: ActorRef) = Props(new Actor {
@ -112,7 +114,7 @@ trait DeathWatchSpec { this: AkkaSpec with ImplicitSender with DefaultTimeout
filterException[ActorKilledException] {
val supervisor = system.actorOf(Props(new Supervisor(
OneForOneStrategy(maxNrOfRetries = 2)(List(classOf[Exception])))))
val terminalProps = Props(new Actor { def receive = { case x sender() ! x } })
val terminalProps = TestActors.echoActorProps
val terminal = Await.result((supervisor ? terminalProps).mapTo[ActorRef], timeout.duration)
val monitor = startWatching(terminal)

View file

@ -31,6 +31,7 @@ object TypedActorSpec {
fixed-pool-size = 60
}
}
akka.actor.serialize-messages = off
"""
class CyclicIterator[T](val items: immutable.Seq[T]) extends Iterator[T] {

View file

@ -16,7 +16,7 @@ object Dependencies {
val junitVersion = "4.12"
val Versions = Seq(
crossScalaVersions := Seq("2.11.8"), // "2.12.0-RC1"
crossScalaVersions := Seq("2.11.8"), // "2.12.0-RC2"
scalaVersion := crossScalaVersions.value.head,
scalaStmVersion := sys.props.get("akka.build.scalaStmVersion").getOrElse("0.7"),
scalaCheckVersion := sys.props.get("akka.build.scalaCheckVersion").getOrElse("1.13.2"),
@ -28,7 +28,6 @@ object Dependencies {
},
java8CompatVersion := {
scalaVersion.value match {
case x if x.startsWith("2.12.0-RC1") => "0.8.0-RC7"
case x if x.startsWith("2.12.0") => "0.8.0-RC8"
case _ => "0.7.0"
}