ShortifyPunit\ShortifyPunit::getMockHierarchyResponse PHP Method

getMockHierarchyResponse() private static method

Returns the mock hierarchy response values
private static getMockHierarchyResponse ( $chainedMethodsBefore, $mockClassType, $mockClassInstanceId ) : mixed
$chainedMethodsBefore
$mockClassType
$mockClassInstanceId
return mixed
    private static function &getMockHierarchyResponse($chainedMethodsBefore, $mockClassType, $mockClassInstanceId)
    {
        $rReturnValues =& self::$returnValues[$mockClassType][$mockClassInstanceId];
        // Check return values chain
        foreach ($chainedMethodsBefore as $chainedMethod) {
            $chainedMethodName = key($chainedMethod);
            $chainedMethodArgs = $chainedMethod[$chainedMethodName];
            $serializedChainMethodArgs = serialize($chainedMethodArgs);
            $rReturnValues =& $rReturnValues[$chainedMethodName][$serializedChainMethodArgs];
        }
        return $rReturnValues;
    }