Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Disable argument cloning in mocked method calls by default.

  • Loading branch information...
commit d8231102fe4db1b2c776b55804a51319152de9b6 1 parent cf17889
@sebastianbergmann authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 PHPUnit/Framework/TestCase.php
View
8 PHPUnit/Framework/TestCase.php
@@ -1297,7 +1297,7 @@ protected function setLocale()
* @throws PHPUnit_Framework_Exception
* @since Method available since Release 3.0.0
*/
- public function getMock($originalClassName, $methods = array(), array $arguments = array(), $mockClassName = '', $callOriginalConstructor = TRUE, $callOriginalClone = TRUE, $callAutoload = TRUE, $cloneArguments = TRUE)
+ public function getMock($originalClassName, $methods = array(), array $arguments = array(), $mockClassName = '', $callOriginalConstructor = TRUE, $callOriginalClone = TRUE, $callAutoload = TRUE, $cloneArguments = FALSE)
{
$mockObject = PHPUnit_Framework_MockObject_Generator::getMock(
$originalClassName,
@@ -1344,7 +1344,7 @@ public function getMockBuilder($className)
* @throws PHPUnit_Framework_Exception
* @since Method available since Release 3.5.0
*/
- protected function getMockClass($originalClassName, $methods = array(), array $arguments = array(), $mockClassName = '', $callOriginalConstructor = FALSE, $callOriginalClone = TRUE, $callAutoload = TRUE, $cloneArguments = TRUE)
+ protected function getMockClass($originalClassName, $methods = array(), array $arguments = array(), $mockClassName = '', $callOriginalConstructor = FALSE, $callOriginalClone = TRUE, $callAutoload = TRUE, $cloneArguments = FALSE)
{
$mock = $this->getMock(
$originalClassName,
@@ -1377,7 +1377,7 @@ protected function getMockClass($originalClassName, $methods = array(), array $a
* @since Method available since Release 3.4.0
* @throws PHPUnit_Framework_Exception
*/
- public function getMockForAbstractClass($originalClassName, array $arguments = array(), $mockClassName = '', $callOriginalConstructor = TRUE, $callOriginalClone = TRUE, $callAutoload = TRUE, $mockedMethods = array(), $cloneArguments = TRUE)
+ public function getMockForAbstractClass($originalClassName, array $arguments = array(), $mockClassName = '', $callOriginalConstructor = TRUE, $callOriginalClone = TRUE, $callAutoload = TRUE, $mockedMethods = array(), $cloneArguments = FALSE)
{
$mockObject = PHPUnit_Framework_MockObject_Generator::getMockForAbstractClass(
$originalClassName,
@@ -1447,7 +1447,7 @@ protected function getMockFromWsdl($wsdlFile, $originalClassName = '', $mockClas
* @since Method available since Release 3.6.0
* @throws PHPUnit_Framework_Exception
*/
- protected function getObjectForTrait($traitName, array $arguments = array(), $traitClassName = '', $callOriginalConstructor = TRUE, $callOriginalClone = TRUE, $callAutoload = TRUE, $cloneArguments = TRUE)
+ protected function getObjectForTrait($traitName, array $arguments = array(), $traitClassName = '', $callOriginalConstructor = TRUE, $callOriginalClone = TRUE, $callAutoload = TRUE, $cloneArguments = FALSE)
{
return PHPUnit_Framework_MockObject_Generator::getObjectForTrait(
$traitName,
Please sign in to comment.
Something went wrong with that request. Please try again.