mirror of
https://github.com/idanoo/php-resque
synced 2025-07-01 05:32:20 +00:00
throw Resque_RedisException whenever an errror connecting/talking to redis occurs
This commit is contained in:
parent
ee9f133bf9
commit
81cb92b964
4 changed files with 49 additions and 27 deletions
|
@ -26,6 +26,15 @@ class Resque_Tests_JobTest extends Resque_Tests_TestCase
|
|||
$this->assertTrue((bool)Resque::enqueue('jobs', 'Test_Job'));
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException Resque_RedisException
|
||||
*/
|
||||
public function testRedisErrorThrowsExceptionOnJobCreation()
|
||||
{
|
||||
Resque::setBackend('redis://255.255.255.255:1234');
|
||||
Resque::enqueue('jobs', 'This is a test');
|
||||
}
|
||||
|
||||
public function testQeueuedJobCanBeReserved()
|
||||
{
|
||||
Resque::enqueue('jobs', 'Test_Job');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue