コード例 #1
0
ファイル: WorkerTest.php プロジェクト: shonm/php-resque
 public function testWorkerFailsUncompletedJobsOnExit()
 {
     $worker = new Worker('jobs');
     $worker->registerWorker();
     $payload = array('class' => 'Test_Job');
     $job = new Job('jobs', $payload);
     $worker->workingOn($job);
     $worker->unregisterWorker();
     $this->assertEquals(1, Stat::get('failed'));
 }