Skip to content

Commit 37f036b

Browse files
committed
WIP
1 parent df6349a commit 37f036b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/Integration/Queue/JobDispatchingTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,12 +144,14 @@ public function testDispatchDeferDelaysDispatchingUntilDeferredCallbacksAreRun()
144144
{
145145
Job::dispatchDefer('test');
146146

147+
$this->assertSame(1, $this->app[DeferredCallbackCollection::class]->count());
147148
$this->assertFalse(Job::$ran);
149+
148150
$this->runQueueWorkerCommand(['--stop-when-empty' => true]);
149151
$this->assertFalse(Job::$ran);
150152

151-
$this->app->get(DeferredCallbackCollection::class)->invoke();
152-
$this->runQueueWorkerCommand(['--stop-when-empty' => true]);
153+
$this->app[DeferredCallbackCollection::class]->invoke();
154+
$this->runQueueWorkerCommand(['--once' => true]);
153155
$this->assertTrue(Job::$ran);
154156
}
155157

0 commit comments

Comments
 (0)