capybara/virtualenv/lib/python2.7/site-packages/werkzeug/debug/__init__.py
def get_resource(self, request, filename):
        """Return a static resource from the shared folder."""
        filename = join(dirname(__file__), 'shared', basename(filename))
        if isfile(filename):
            mimetype = mimetypes.guess_type(filename)[0] \
                or 'application/octet-stream'
            f = open(filename, 'rb')
            try:
                return Response(f.read(), mimetype=mimetype)
            finally:
                f.close()
        return Response('Not Found', status=404)
def get_resource(self, request, filename):
        filename = join(dirname(__file__), 'shared', basename(filename))
        if isfile(filename):
            mimetype = mimetypes.guess_type(filename)[0] \
                or 'application/octet-stream'
            f = open(filename, 'rb')
            try:
                return Response(f.read(), mimetype=mimetype)
            finally:
                f.close()
        return Response('Not Found', status=404)
def get_resource ( self , request , filename ) : filename = join ( dirname ( __file__ ) , 'shared' , basename ( filename ) ) if isfile ( filename ) : mimetype = mimetypes . guess_type ( filename ) [ 0 ] or 'application/octet-stream' f = open ( filename , 'rb' ) try : return Response ( f . read ( ) , mimetype = mimetype ) finally : f . close ( ) return Response ( 'Not Found' , status = 404 )
Return a static resource from the shared folder.
Return a static resource from the shared folder .