@@ -4,6 +4,7 @@ import scala.concurrent.duration.{ DurationInt, FiniteDuration }
4
4
import scala .util .Try
5
5
import org .scalatest .{ BeforeAndAfterAll , Matchers , WordSpec }
6
6
import com .reactivedesignpatterns .Defaults ._
7
+ import com .reactivedesignpatterns .Helpers
7
8
import akka .actor .{ Actor , ActorRef , ActorSystem , Props , actorRef2Scala }
8
9
import akka .testkit .TestProbe
9
10
import akka .util .Timeout
@@ -141,7 +142,8 @@ akka.actor.default-dispatcher.fork-join-executor.parallelism-max = 3
141
142
val sorted = timings.sorted
142
143
val ninetyfifthPercentile = sorted.dropRight(N * 5 / 100 ).last
143
144
info(s " SLA min= ${sorted.head} max= ${sorted.last} 95th= $ninetyfifthPercentile" )
144
- ninetyfifthPercentile should be < 1 .millisecond
145
+ val SLA = if (Helpers .isCiTest) 10 .milliseconds else 1 .millisecond
146
+ ninetyfifthPercentile should be < SLA
145
147
}
146
148
147
149
" keep its SLA when used in parallel with Futures" in {
@@ -183,7 +185,8 @@ akka.actor.default-dispatcher.fork-join-executor.parallelism-max = 3
183
185
val sorted = result.timings.sorted
184
186
val ninetyfifthPercentile = sorted.dropRight(N * 5 / 100 ).last
185
187
info(s " SLA min= ${sorted.head} max= ${sorted.last} 95th= $ninetyfifthPercentile" )
186
- ninetyfifthPercentile should be < 2 .milliseconds
188
+ val SLA = if (Helpers .isCiTest) 10 .milliseconds else 2 .milliseconds
189
+ ninetyfifthPercentile should be < SLA
187
190
}
188
191
189
192
}
@@ -207,4 +210,4 @@ akka.actor.default-dispatcher.fork-join-executor.parallelism-max = 3
207
210
208
211
}
209
212
210
- }
213
+ }
0 commit comments