File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 2
2
3
3
namespace Illuminate \Tests \Support ;
4
4
5
+ use Illuminate \Bus \Queueable ;
5
6
use Illuminate \Contracts \Bus \QueueingDispatcher ;
6
7
use Illuminate \Support \Testing \Fakes \BusFake ;
7
8
use Mockery as m ;
@@ -376,6 +377,19 @@ public function testAssertNothingDispatched()
376
377
}
377
378
}
378
379
380
+ public function testAssertChained ()
381
+ {
382
+ $ this ->fake ->chain ([
383
+ new ChainedJobStub ,
384
+ new OtherBusJobStub ,
385
+ ])->dispatch ();
386
+
387
+ $ this ->fake ->assertChained ([
388
+ ChainedJobStub::class,
389
+ OtherBusJobStub::class,
390
+ ]);
391
+ }
392
+
379
393
public function testAssertDispatchedWithIgnoreClass ()
380
394
{
381
395
$ dispatcher = m::mock (QueueingDispatcher::class);
@@ -447,6 +461,11 @@ class BusJobStub
447
461
//
448
462
}
449
463
464
+ class ChainedJobStub
465
+ {
466
+ use Queueable;
467
+ }
468
+
450
469
class OtherBusJobStub
451
470
{
452
471
public $ id ;
You can’t perform that action at this time.
0 commit comments