File tree Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change 24
24
* @method static void assertDispatchedAfterResponseTimes(string $command, int $times = 1)
25
25
* @method static void assertNotDispatchedAfterResponse(string|\Closure $command, callable $callback = null)
26
26
* @method static void assertBatched(callable $callback)
27
+ * @method static void assertBatchCount(int $count)
27
28
* @method static void assertChained(array $expectedChain)
28
29
* @method static void assertDispatchedSync(string|\Closure $command, callable $callback = null)
29
30
* @method static void assertDispatchedSyncTimes(string $command, int $times = 1)
Original file line number Diff line number Diff line change @@ -413,6 +413,19 @@ public function assertBatched(callable $callback)
413
413
);
414
414
}
415
415
416
+ /**
417
+ * Assert the number of batches that have been dispatched.
418
+ *
419
+ * @param int $count
420
+ * @return void
421
+ */
422
+ public function assertBatchCount ($ count )
423
+ {
424
+ PHPUnit::assertCount (
425
+ $ count , $ this ->batches ,
426
+ );
427
+ }
428
+
416
429
/**
417
430
* Get all of the jobs matching a truth-test callback.
418
431
*
You can’t perform that action at this time.
0 commit comments