Skip to content

Commit

Permalink
more coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
nickolai-dr authored and jettify committed Jul 4, 2016
1 parent 9fd6bd0 commit 020f198
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tests/test_web_request.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import pytest
from unittest import mock

from multidict import MultiDict, CIMultiDict
from aiohttp.protocol import HttpVersion
Expand Down Expand Up @@ -30,6 +31,20 @@ def test_ctor(make_request, warning):

assert req.keep_alive

# just make sure that all lines of make_mocked_request covered
reader = mock.Mock()
writer = mock.Mock()
payload = mock.Mock()
transport = mock.Mock()
app = mock.Mock()
req = make_request('GET', '/path/to?a=1&b=2', writer=writer, reader=reader,
payload=payload, transport=transport, app=app)
assert req.app is app
assert req.content is payload
assert req.transport is transport
assert req._reader is reader
assert req._writer is writer


def test_doubleslashes(make_request):
req = make_request('GET', '//foo/')
Expand Down

0 comments on commit 020f198

Please sign in to comment.