Fix tests.

This commit is contained in:
Raza Mehdi
2020-08-15 01:14:13 +05:00
parent 882d59001f
commit 5edf443141
189 changed files with 1272 additions and 2034 deletions
+7 -7
View File
@@ -28,7 +28,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('key1', 'key2', 'value1', 'value2');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));
@@ -47,7 +47,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('key1', 'key2', 'value1', 'value2');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));
@@ -66,7 +66,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('value1', 'value2', 'value3');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));
@@ -85,7 +85,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('key1', 'key2', 'value1', 'value2');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));
@@ -104,7 +104,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('value1', 'value2', 'value3');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));
@@ -123,7 +123,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('key1', 'key2', 'value1', 'value2');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));
@@ -142,7 +142,7 @@ class ScriptCommandTest extends PredisTestCase
{
$arguments = array('key1', 'key2', 'value1', 'value2');
$command = $this->getMock('Predis\Command\ScriptCommand', array('getScript', 'getKeysCount'));
$command = $this->getMockBuilder('Predis\Command\ScriptCommand')->setMethods(array('getScript', 'getKeysCount'))->getMock();
$command->expects($this->once())
->method('getScript')
->will($this->returnValue(self::LUA_SCRIPT));