Closed thepsion5 closed 10 years ago
Thanks. I'll take a look at it tonight.
Hey, I made this repo as a test case (https://github.com/philipbrown/test_project)
Can you take a look to see if it looks set up correctly? I can't seem to replicate your error.
In your ExampleTest
class, you need to make sure that Mockery is cleaning itself up before creating another instance of itself. Include the following method in your class. It should fix the error.
public function tearDown()
{
Mockery::close();
}
Thanks @searsaw :)
I'm not 100% sure if this is an issue with Magniloquent itself or Mockery, but attempting to mock a class that extends Magniloquent results in a fatal error.
My composer.json's requirements:
My model:
And my test:
Running $ vendor/bin/phpunit results in the following: