private function getChainedMockCounter($methods)
    {
        $mockReturnValues = ShortifyPunit::getReturnValues();

        $mockResponse = $mockReturnValues[$this->mockedClass][$this->instanceId];

        foreach ($methods as $method)
        {
            $methodName = key($method);
            $args = $method[$methodName];
            $serializedArgs = serialize($args);

            if ( ! isset($mockResponse[$methodName][$serializedArgs]))
            {
                if ( ! isset($mockResponse[$methodName])) {
                    break;
                }

                // try to finding matching Hamcrest-API Function (anything(), equalTo())
                $serializedArgs = static::checkMatchingArguments($mockResponse[$methodName], $args);

                if (is_null($serializedArgs)) {
                    break;
                }
            }

            $mockResponse = $mockResponse[$methodName][$serializedArgs];
        }

        return isset($mockResponse['response']['counter']) ? $mockResponse['response']['counter'] : 0;
    }