MongolidLaravel\MongolidModel::__callStatic PHP Method

__callStatic() public static method

Initiate a mock expectation on the facade.
public static __callStatic ( string $name, array $arguments ) : Expectation | void
$name string Name of the method being called.
$arguments array Method arguments.
return Mockery\Expectation | void
    public static function __callStatic($name, $arguments)
    {
        if ($name === 'shouldReceive') {
            $class = get_called_class();
            static::$mock[$class] = static::$mock[$class] ?? Mockery::mock();
            return static::$mock[$class]->shouldReceive(...$arguments);
        }
    }