Skip to content
This repository has been archived by the owner on Feb 20, 2023. It is now read-only.

PHPUnit_Framework_MockObject_MockBuilder::getMock() calls PHPUnit_Framework_TestCase::getMock() with more arguments than accepted #301

Closed
sebastianbergmann opened this issue Apr 12, 2016 · 3 comments
Assignees
Labels

Comments

@sebastianbergmann
Copy link
Owner

    public function getMock()
    {
        return $this->testCase->getMock(
            $this->type,
            $this->methods,
            $this->constructorArgs,
            $this->mockClassName,
            $this->originalConstructor,
            $this->originalClone,
            $this->autoload,
            $this->cloneArguments,
            $this->callOriginalMethods,
            $this->proxyTarget
        );
    }
    public function getMock($originalClassName, $methods = [], array $arguments = [], $mockClassName = '', $callOriginalConstructor = true, $callOriginalClone = true, $callAutoload = true, $cloneArguments = false, $callOriginalMethods = false)
    {

This probably means that PHPUnit_Framework_MockObject_MockBuilder::setProxyTarget() has no effect.

@TimothyBJacobs
Copy link
Sponsor

@sebastianbergmann Is there any chance this can be backdated to the 4.8 branch? I ran into this today. Or is there an alternative workaround?

@sebastianbergmann
Copy link
Owner Author

@TimothyBJacobs Done.

sebastianbergmann added a commit to sebastianbergmann/phpunit that referenced this issue May 17, 2016
@TimothyBJacobs
Copy link
Sponsor

Thanks, much appreciated.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants