Implementation of org.reactivestreams.Publisher that allows various assertions. This probe does not track demand. Therefore you need to expect demand before sending elements downstream.
Attributes
- Companion
- object
- Source
- StreamTestKit.scala
- Graph
-
- Supertypes
- Known subtypes
-
class Probe[T]
Members list
Type members
Types
Attributes
- Source
- StreamTestKit.scala
Value members
Concrete methods
Attributes
- Source
- StreamTestKit.scala
JAVA API
Attributes
- Source
- StreamTestKit.scala
Expect no messages. Waits for the default period configured as pekko.actor.testkit.expect-no-message-default.
Expect no messages. Waits for the default period configured as pekko.actor.testkit.expect-no-message-default.
Attributes
- Source
- StreamTestKit.scala
Expect no messages for a given duration.
JAVA API
Expect demand from a given subscription.
Expect a subscription.
Attributes
- Source
- StreamTestKit.scala
Receive messages for a given duration or until one does not match a given partial function.
Receive messages for a given duration or until one does not match a given partial function.
Attributes
- Source
- StreamTestKit.scala
JAVA API
JAVA API
Receive messages for a given duration or until one does not match a given partial function.
Attributes
- Since
-
1.1.0
- Source
- StreamTestKit.scala
Subscribes a given org.reactivestreams.Subscriber to this probe publisher.
Subscribes a given org.reactivestreams.Subscriber to this probe publisher.
Attributes
- Source
- StreamTestKit.scala
Execute code block while bounding its execution time between min and max. within blocks may be nested. All methods in this trait which take maximum wait times are available in a version which implicitly uses the remaining time governed by the innermost enclosing within block.
Execute code block while bounding its execution time between min and max. within blocks may be nested. All methods in this trait which take maximum wait times are available in a version which implicitly uses the remaining time governed by the innermost enclosing within block.
Note that the timeout is scaled using Duration.dilated, which uses the configuration entry "pekko.test.timefactor", while the min Duration is not.
val ret = within(50 millis) {
test ! "ping"
expectMsgClass(classOf[String])
}
Attributes
- Source
- StreamTestKit.scala
JAVA API
JAVA API
Execute code block while bounding its execution time between min and max. within blocks may be nested. All methods in this trait which take maximum wait times are available in a version which implicitly uses the remaining time governed by the innermost enclosing within block.
Note that the timeout is scaled using Duration.dilated, which uses the configuration entry "pekko.test.timefactor", while the min Duration is not.
val ret = within(Duration.ofMillis(50)) {
test ! "ping"
expectMsgClass(classOf[String])
}
Attributes
- Since
-
1.1.0
- Source
- StreamTestKit.scala
Same as calling within(0 seconds, max)(f).
JAVA API
JAVA API
Same as calling within(Duration.ofSeconds(0), max)(f).
Attributes
- Since
-
1.1.0
- Source
- StreamTestKit.scala
Deprecated methods
Expect no messages. NOTE! Timeout value is automatically multiplied by timeFactor.
Expect no messages. NOTE! Timeout value is automatically multiplied by timeFactor.
Attributes
- Deprecated
-
[Since version Akka 2.5.5]Use expectNoMessage instead - Source
- StreamTestKit.scala
Expect no messages for a given duration. NOTE! Timeout value is automatically multiplied by timeFactor.
Expect no messages for a given duration. NOTE! Timeout value is automatically multiplied by timeFactor.
Attributes
- Deprecated
-
[Since version Akka 2.5.5]Use expectNoMessage instead - Source
- StreamTestKit.scala