test_query_params.py 文件源码

python
阅读 18 收藏 0 点赞 0 评论 0

项目:deb-python-falcon 作者: openstack 项目源码 文件源码
def test_dont_auto_parse_by_default(self):
        app = falcon.API()
        resource = testing.SimpleTestResource()
        app.add_route('/', resource)

        client = testing.TestClient(app)

        headers = {'Content-Type': 'application/x-www-form-urlencoded'}
        client.simulate_request(path='/', body='q=42', headers=headers)

        req = resource.captured_req
        assert req.get_param('q') is None
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号