File tree Expand file tree Collapse file tree 5 files changed +11
-7
lines changed
main/scala/app/softnetwork/scheduler
test/scala/app/softnetwork/scheduler/api Expand file tree Collapse file tree 5 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ ThisBuild / organization := "app.softnetwork"
3131
3232name := " scheduler"
3333
34- ThisBuild / version := " 0.1.1 "
34+ ThisBuild / version := " 0.1.2 "
3535
3636ThisBuild / scalaVersion := " 2.12.15"
3737
Original file line number Diff line number Diff line change @@ -9,5 +9,5 @@ trait SchedulerGrpcServer
99 extends PersistenceScalatestGrpcTest
1010 with SchedulerGrpcServices
1111 with InMemoryPersistenceTestKit { _ : Suite with SchedulerGuardian =>
12- override lazy val additionalConfig : String = grpcConfig
12+ override lazy val additionalConfig : String = schedulerGrpcConfig
1313}
Original file line number Diff line number Diff line change @@ -15,11 +15,15 @@ trait SchedulerGrpcServices extends GrpcServices {
1515
1616 def port : Int
1717
18- final override def grpcServices
18+ override def grpcServices
19+ : ActorSystem [_] => Seq [PartialFunction [HttpRequest , Future [HttpResponse ]]] =
20+ schedulerGrpcServices
21+
22+ def schedulerGrpcServices
1923 : ActorSystem [_] => Seq [PartialFunction [HttpRequest , Future [HttpResponse ]]] = system =>
2024 Seq (SchedulerServiceApiHandler .partial(schedulerServer(system))(system))
2125
22- def grpcConfig : String = s """
26+ def schedulerGrpcConfig : String = s """
2327 |# Important: enable HTTP/2 in ActorSystem's config
2428 |akka.http.server.preview.enable-http2 = on
2529 |akka.grpc.client." ${SchedulerClient .name}"{
Original file line number Diff line number Diff line change @@ -2,14 +2,14 @@ package app.softnetwork.scheduler.scalatest
22
33import akka .actor .typed .ActorSystem
44import app .softnetwork .persistence .query .InMemoryJournalProvider
5- import app .softnetwork .scheduler . api . SchedulerGrpcServer
5+ import app .softnetwork .persistence . scalatest . InMemoryPersistenceTestKit
66import app .softnetwork .scheduler .config .SchedulerSettings
77import app .softnetwork .scheduler .handlers .SchedulerHandler
88import app .softnetwork .scheduler .launch .SchedulerGuardian
99import app .softnetwork .scheduler .persistence .query .Entity2SchedulerProcessorStream
1010import org .scalatest .Suite
1111
12- trait SchedulerTestKit extends SchedulerGuardian with SchedulerGrpcServer {
12+ trait SchedulerTestKit extends SchedulerGuardian with InMemoryPersistenceTestKit {
1313 _ : Suite =>
1414
1515 /** @return
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ import app.softnetwork.scheduler.scalatest.SchedulerTestKit
44import org .scalatest .wordspec .AnyWordSpecLike
55import org .softnetwork .akka .model .Schedule
66
7- class SchedulerClientSpec extends AnyWordSpecLike with SchedulerTestKit {
7+ class SchedulerClientSpec extends AnyWordSpecLike with SchedulerTestKit with SchedulerGrpcServer {
88
99 lazy val client : SchedulerClient = SchedulerClient (typedSystem())
1010
You can’t perform that action at this time.
0 commit comments