/
githubmirror
/
framework
Обзор
Документация
Войти
/
githubmirror
/
framework
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
13.x
tests/Integration/Console/Scheduling/QueuePauseCommandTest.php
33 строки
690 B
Wes Hooper
[13.x] Display error in `queue:pause` when `Worker` isn't pausable (#60023)
08 май 2026, 16:46
Не верифицирован
08 май 2026, 16:46
94f1ad1
Код
Авторство
О чём код?
<?php namespace Illuminate\Tests\Integration\Console\Scheduling; use Illuminate\Queue\Events\QueuePaused; use Illuminate\Queue\Worker; use Illuminate\Support\Facades\Event; use Orchestra\Testbench\TestCase; class QueuePauseCommandTest extends TestCase { public function testDispatchesEvent() { Event::fake(); $this->artisan('queue:pause default'); Event::assertDispatched(QueuePaused::class); } public function testDisabledError() { Event::fake(); Worker::$pausable = false; $this->artisan('queue:pause default'); Event::assertNotDispatched(QueuePaused::class); Worker::$pausable = true; } }