mirror of
https://github.com/predis/predis.git
synced 2026-08-30 04:02:22 +00:00
Fix test error exception for SELECT command
This commit is contained in:
@@ -71,12 +71,24 @@ class ConnectionSelectTest extends PredisCommandTestCase
|
||||
/**
|
||||
* @group connected
|
||||
* @expectedException \Predis\Response\ServerException
|
||||
* @expectedExceptionMessage ERR invalid DB index
|
||||
* @expectedExceptionMessage ERR DB index is out of range
|
||||
*/
|
||||
public function testThrowsExceptionOnUnexpectedDatabase()
|
||||
public function testThrowsExceptionOnUnexpectedDatabaseRange()
|
||||
{
|
||||
$redis = $this->getClient();
|
||||
|
||||
$redis->select(100000000);
|
||||
}
|
||||
|
||||
/**
|
||||
* @group connected
|
||||
* @expectedException \Predis\Response\ServerException
|
||||
* @expectedExceptionMessage ERR invalid DB index
|
||||
*/
|
||||
public function testThrowsExceptionOnUnexpectedDatabaseName()
|
||||
{
|
||||
$redis = $this->getClient();
|
||||
|
||||
$redis->select('x');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user