Compile akka-actor-testkit with scala 3 (#30395)

Interestingly the Java code in the tests now doesn't compile, so something
around generics might still be wrong.
This commit is contained in:
Arnout Engelen 2021-07-19 13:10:48 +02:00 committed by GitHub
parent 9d4e838efa
commit 276778e157
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 4 deletions

View file

@ -38,7 +38,7 @@ jobs:
- stage: scala3
name: scala3
# separate job since only a few modules compile with Scala 3 yet
script: jabba install adopt@1.11-0 && jabba use adopt@1.11-0 && sbt -Dakka.build.scalaVersion=3.0 "akka-actor-tests/test:compile" akka-actor-typed/compile akka-pki/test:compile akka-protobuf/test:compile akka-protobuf-v3/test:compile akka-slf4j/test:compile akka-stream/compile akka-stream-tests-tck/test
script: jabba install adopt@1.11-0 && jabba use adopt@1.11-0 && sbt -Dakka.build.scalaVersion=3.0 "akka-actor-tests/test:compile" akka-actor-testkit-typed/compile akka-actor-typed/compile akka-pki/test:compile akka-protobuf/test:compile akka-protobuf-v3/test:compile akka-slf4j/test:compile akka-stream/compile akka-stream-tests-tck/test
stages:
- name: whitesource

View file

@ -44,7 +44,7 @@ object TestKitSettings {
private object Ext extends ExtensionId[Ext] {
override def createExtension(system: ActorSystem[_]): Ext = new Ext(system)
def get(system: ActorSystem[_]): Ext = apply(system)
def get(system: ActorSystem[_]): Ext = Ext.apply(system)
}
private class Ext(system: ActorSystem[_]) extends Extension {

View file

@ -30,7 +30,7 @@ private[akka] final class BehaviorTestKitImpl[T](_path: ActorPath, _initialBehav
with akka.actor.testkit.typed.scaladsl.BehaviorTestKit[T] {
// really this should be private, make so when we port out tests that need it
private[akka] val context = new EffectfulActorContext[T](_path, () => currentBehavior)
private[akka] val context: EffectfulActorContext[T] = new EffectfulActorContext[T](_path, () => currentBehavior)
private[akka] def as[U]: BehaviorTestKitImpl[U] = this.asInstanceOf[BehaviorTestKitImpl[U]]

View file

@ -76,7 +76,7 @@ private[akka] final class FunctionRef[-T](override val path: ActorPath, send: (T
@InternalApi private[akka] val selfInbox = new TestInboxImpl[T](path)
override val self = selfInbox.ref
override val system = new ActorSystemStub("StubbedActorContext")
override val system: ActorSystemStub = new ActorSystemStub("StubbedActorContext")
private var _children = TreeMap.empty[String, BehaviorTestKitImpl[_]]
private val childName = Iterator.from(0).map(Helpers.base64(_))
private val substituteLoggerFactory = new SubstituteLoggerFactory