Hi,

We are trying to create a BehaviorTestKit using a behavior which spawns a 
timer within.

val behaviorTestKit = BehaviorTestKit(createBehavior)


private def createBehavior(): Behavior[MyMessage] = {
  Behaviors
    .withTimers[MyMessage](
      timerScheduler ⇒
        Behaviors
          .mutable[MyMessage](
            ctx =>
              new MyBehavior(
                ctx,
                timerScheduler,
                someInfo
            )
        )
    )
}


The above code results in error below:

An exception or error caused a run to abort: no scheduler 
java.lang.UnsupportedOperationException: no scheduler

*spawn *provided in ActorTestKit works fine in spawning an actor for this 
behavior.

However, we need to test the underlying effects of the given behavior and 
hence need to use BehaviorTestKit.
Could someone please provide a solution to this problem?

Thanks and Regards,
Dolly
ThoughtWorks

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at https://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to