File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
tests/src/test/scala/org/apache/openwhisk/core/scheduler/queue/test Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -206,7 +206,11 @@ class MemoryQueueTests
206
206
expectDurationChecking(mockEsClient, testInvocationNamespace)
207
207
208
208
val queueConfigWithShortTimeout =
209
- queueConfig.copy(idleGrace = 10 .seconds, stopGrace = 10 .milliseconds, gracefulShutdownTimeout = 10 .milliseconds)
209
+ queueConfig.copy(
210
+ idleGrace = 10 .seconds,
211
+ stopGrace = 10 .milliseconds,
212
+ gracefulShutdownTimeout = 10 .milliseconds,
213
+ flushGrace = 10 .milliseconds)
210
214
211
215
val fsm =
212
216
TestFSMRef (
@@ -249,6 +253,10 @@ class MemoryQueueTests
249
253
// state Running -> Flushing
250
254
expectMsg(Transition (fsm, Running , Flushing ))
251
255
fsm.isTimerActive(" StopQueue" ) shouldBe true
256
+
257
+ // wait for flushGrace time, StopQueue timer should send StateTimeout
258
+ Thread .sleep(queueConfigWithShortTimeout.flushGrace.toMillis)
259
+ expectMsg(Transition (fsm, Flushing , Removed ))
252
260
}
253
261
254
262
it should " register the endpoint when initializing" in {
You can’t perform that action at this time.
0 commit comments