for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace App\Ship\Features\Tests\PhpUnit;
use App;
use Mockery;
/**
* Class TestsMockHelperTrait
*
* Tests helper for mocking objects and services.
* @author Mahmoud Zalt <[email protected]>
*/
trait TestsMockHelperTrait
{
* Mocking helper
* @param $class
* @return \Mockery\MockInterface
public function mock($class)
$mock = Mockery::mock($class);
App::instance($class, $mock);
return $mock;
}