TestBase::callStatic PHP Method

callStatic() public method

Calls a class method even if it is protected or private
public callStatic ( string $class, string $methodName, mixed $args = null ) : mixed
$class string the class to call a method on
$methodName string the method name to be called
$args mixed 0 or more arguments passed in the function
return mixed returns what the object's method call will return
    public function callStatic($class, $methodName, $args = null)
    {
        $args = func_get_args();
        array_shift($args);
        array_shift($args);
        return self::_callMethod($class, $methodName, $args);
    }