SimpleMock::dieOnNoMethod PHP Method

dieOnNoMethod() protected method

Triggers a PHP error if the method is not part of this object.
protected dieOnNoMethod ( string $method, string $task )
$method string Name of method.
$task string Description of task attempt.
    protected function dieOnNoMethod($method, $task)
    {
        if ($this->is_strict && !method_exists($this, $method)) {
            $errormsg = sprintf('Cannot %s. Method %s() not in class %s.', $task, $method, get_class($this));
            trigger_error($errormsg, E_USER_ERROR);
        }
    }