vendorjb/RamlApiTester/PHPUnitTestCase.php
/**
     * @param  array $coverage
     * @return array
     * @author Mattis Stordalen Flister <mattis@xait.no>
     */
@param  array $coverage
@return array
@author Mattis Stordalen Flister 
@param array $coverage @return array @author Mattis Stordalen Flister
protected function matchLocalAndRemotePaths(array $coverage)
    {
        $coverageWithLocalPaths = array();
        foreach ($coverage as $originalRemotePath => $data) {
            $remotePath = $originalRemotePath;
            $separator  = $this->findDirectorySeparator($remotePath);
            while (!($localpath = stream_resolve_include_path($remotePath)) &&
                   strpos($remotePath, $separator) !== FALSE) {
                $remotePath = substr($remotePath, strpos($remotePath, $separator) + 1);
            }
            if ($localpath && md5_file($localpath) == $data['md5']) {
                $coverageWithLocalPaths[$localpath] = $data['coverage'];
            }
        }
        return $coverageWithLocalPaths;
    }
protected function matchLocalAndRemotePaths ( array $ coverage ) { $ coverageWithLocalPaths = array ( ) ; foreach ( $ coverage as $ originalRemotePath => $ data ) { $ remotePath = $ originalRemotePath ; $ separator = $ this -> findDirectorySeparator ( $ remotePath ) ; while ( ! ( $ localpath = stream_resolve_include_path ( $ remotePath ) ) && strpos ( $ remotePath , $ separator ) !== FALSE ) { $ remotePath = substr ( $ remotePath , strpos ( $ remotePath , $ separator ) + 1 ) ; } if ( $ localpath && md5_file ( $ localpath ) == $ data [ 'md5' ] ) { $ coverageWithLocalPaths [ $ localpath ] = $ data [ 'coverage' ] ; } } return $ coverageWithLocalPaths ; }
@param  array $coverage
 @return array
 @author Mattis Stordalen Flister <mattis@xait.no>
@param array $coverage @return array @author Mattis Stordalen Flister <mattis@xait . no >