Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mocking class Imagick of pecl/imagick 3.0.0 fails with PHPUnit 3.4.2 and 3.5 beta1 #3

Closed
lstrojny opened this issue Aug 7, 2010 · 1 comment

Comments

@lstrojny
Copy link
Contributor

lstrojny commented Aug 7, 2010

When mocking class Imagick of the pecl/imagick extension 3.0.0, mocking fails with the following error message:

Fatal error: Call to a member function verify() on a non-object in /usr/share/php/PHPUnit/Framework/MockObject/Generator.php(172) : eval()'d code on line 4358

The testcase is quite easy:

class test extends PHPUnit_Framework_TestCase
{
public function test()
{
$mock = $this->getMock('Imagick');
}
}

The server is running Ubunt 10.04 with PHP 5.3.2 from the Ubuntu repository, Imagick installed via pecl and PHPUnit installed from PEAR.

@sebastianbergmann
Copy link
Owner

Not a phpunit issue, please open a ticket with phpunit-mock-objects.

axiac pushed a commit to axiac/phpunit that referenced this issue May 8, 2018
@shinseihasu shinseihasu mentioned this issue Jul 31, 2019
Closed
glensc pushed a commit to glensc/php-phpunit that referenced this issue Oct 4, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants