PHPSpec2\Prophet\ObjectProphet::__call PHP Method

__call() public method

public __call ( $method, array $arguments = [] )
$arguments array
    public function __call($method, array $arguments = array())
    {
        // if user calls function with should prefix - call matcher
        if (preg_match('/^(should(?:Not|))(.+)$/', $method, $matches)) {
            $matcherName = lcfirst($matches[2]);
            if ('should' === $matches[1]) {
                return $this->should($matcherName, $arguments);
            }
            return $this->shouldNot($matcherName, $arguments);
        }
        return $this->callOnProphetSubject($method, $arguments);
    }