Skip to content

Commit

Permalink
Proto scala testkig start config (#2203)
Browse files Browse the repository at this point in the history
* chore: add start(config) to protobuf KalixTestKit

* fix scaladoc complaint
  • Loading branch information
sebastian-alfers authored Aug 26, 2024
1 parent 75559b2 commit cf676c9
Showing 1 changed file with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import scala.concurrent.ExecutionContext

import akka.actor.ActorSystem
import akka.stream.Materializer
import com.typesafe.config.Config
import kalix.scalasdk.{ Kalix, Principal }
import kalix.javasdk.testkit.{ KalixTestKit => JTestKit }
import kalix.javasdk.testkit.KalixTestKit.Settings.{ EventingSupport => JEventingSupport }
Expand All @@ -25,7 +26,7 @@ import kalix.javasdk.impl.MessageCodec
*
* <p>Requires Docker for starting a local instance of the Kalix Runtime.
*
* <p>Create a KalixTestKit with an [[Kalix]] service descriptor, and then [[KalixTestKit.start]] the testkit before
* <p>Create a KalixTestKit with an [[Kalix]] service descriptor, and then [[KalixTestKit.start()*]] the testkit before
* testing the service with gRPC or HTTP clients. Call [[KalixTestKit.stop]] after tests are complete.
*/
object KalixTestKit {
Expand Down Expand Up @@ -104,6 +105,15 @@ class KalixTestKit private (delegate: JTestKit) {
this
}

/**
* @param config
* @return
*/
def start(config: Config): KalixTestKit = {
delegate.start(config)
this
}

/**
* Get an Akka gRPC client for the given service name. The same client instance is shared for the test. The lifecycle
* of the client is managed by the SDK and it should not be stopped by user code.
Expand Down

0 comments on commit cf676c9

Please sign in to comment.