lithium\test\Mocker::_namespace PHP Method

_namespace() protected static method

Will generate the namespace from the current mockee.
protected static _namespace ( string $mockee ) : string
$mockee string The fully namespaced `\Mock` class
return string
    protected static function _namespace($mockee)
    {
        $matches = array();
        preg_match_all('/^(.*)\\\\Mock$/', $mockee, $matches);
        return isset($matches[1][0]) ? $matches[1][0] : null;
    }