Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(26)  |  Call(26)  |  Derive(0)  |  Import(0)

src/m/a/mapproxy-HEAD/mapproxy/test/unit/test_response.py   mapproxy(Download)
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        result = resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert result.next() == 'string content'
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        result = resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert result.next() == 'string content'
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        result = resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert result.next() == 'foobar'
        file_wrapper = self.mock()
        self.expect(file_wrapper(data, resp.block_size)).result('DUMMY')
        self.replay()
 
        result = resp({'REQUEST_METHOD': 'GET',
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert resp.content_length == 342

src/m/a/mapproxy-HEAD/mapproxy/test/unit/test_exceptions.py   mapproxy(Download)
        self.expect(ex_handler.render(req_ex))
 
        self.replay()
        req_ex.render()
 
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'

src/m/a/MapProxy-1.6.0/mapproxy/test/unit/test_response.py   MapProxy(Download)
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        result = resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert result.next() == 'string content'
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        result = resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert result.next() == 'string content'
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        result = resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert result.next() == 'foobar'
        file_wrapper = self.mock()
        self.expect(file_wrapper(data, resp.block_size)).result('DUMMY')
        self.replay()
 
        result = resp({'REQUEST_METHOD': 'GET',
        start_response = self.mock()
        self.expect(start_response('200 OK', ANY))
        self.replay()
        resp({'REQUEST_METHOD': 'GET'}, start_response)
        assert resp.content_length == 342

src/m/a/MapProxy-1.6.0/mapproxy/test/unit/test_exceptions.py   MapProxy(Download)
        self.expect(ex_handler.render(req_ex))
 
        self.replay()
        req_ex.render()
 
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'
        self.expect(req.exception_handler).result(ex_handler)
 
        self.replay()
        response = req_ex.render()
        assert response.content_type == 'application/vnd.ogc.se_xml'