Include imports in the GraphStage logging snippets (#23378)

This commit is contained in:
Arnout Engelen 2017-07-19 06:11:59 -07:00 committed by Konrad `ktoso` Malawski
parent d083fcffd8
commit aec87a94c4
2 changed files with 10 additions and 3 deletions

View file

@ -7,7 +7,6 @@ import java.util.concurrent.ThreadLocalRandom
import akka.stream._
import akka.stream.scaladsl._
import akka.stream.stage.{ GraphStage, GraphStageLogic, OutHandler, StageLogging }
import akka.testkit.{ AkkaSpec, EventFilter }
class GraphStageLoggingDocSpec extends AkkaSpec("akka.loglevel = DEBUG") {
@ -16,6 +15,8 @@ class GraphStageLoggingDocSpec extends AkkaSpec("akka.loglevel = DEBUG") {
implicit val ec = system.dispatcher
//#stage-with-logging
import akka.stream.stage.{ GraphStage, GraphStageLogic, OutHandler, StageLogging }
final class RandomLettersSource extends GraphStage[SourceShape[String]] {
val out = Outlet[String]("RandomLettersSource.out")
override val shape: SourceShape[String] = SourceShape(out)