(create_app_and_client)
| 117 | |
| 118 | @pytest.mark.run_loop |
| 119 | def test_auto_header_user_agent(create_app_and_client): |
| 120 | @asyncio.coroutine |
| 121 | def handler(request): |
| 122 | assert 'aiohttp' in request.headers['user-agent'] |
| 123 | return web.Response() |
| 124 | |
| 125 | app, client = yield from create_app_and_client() |
| 126 | app.router.add_route('GET', '/', handler) |
| 127 | |
| 128 | resp = yield from client.get('/') |
| 129 | try: |
| 130 | assert 200, resp.status |
| 131 | finally: |
| 132 | yield from resp.release() |
| 133 | |
| 134 | |
| 135 | @pytest.mark.run_loop |
nothing calls this directly
no test coverage detected